-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Storybook as a framework to develop and document UI. So far this is groundwork, once the Storybook docs are finished, ./app folder can be deleted. * FIXES Several small fixes to some components such as `Duration` and `CurrentTime`, fixes to the UI and some improvements to the API. * FEATURES Create `PlayPauseIndicator`. Add CSS classes `.pp-ui-layers` and `.pp-ui-layer` intended to stack layers of UI on top of each other (e.g. player and its overlay). * TOOLING In Jest remove `transformIgnorePatterns` of `@castlabs/prestoplay` because it is not being transformed anyway, because it is getting mocked instead.
- Loading branch information
1 parent
96fb14a
commit 4d414e5
Showing
81 changed files
with
2,490 additions
and
330 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,3 +15,7 @@ button.docblock-code-toggle { | |
.sb-clpp-anchor:hover { | ||
color: #58baf6; | ||
} | ||
|
||
.css-79elbk { | ||
display: none; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
/** | ||
* Imports from @react-hook are for some reason not resolved correctly, and they end up | ||
* importing ESM code instead of transpiled ES5 which causes a crash of the test suite. | ||
* Fix it by correcting those paths here. | ||
* | ||
* (The package.json.exports field in @react-hook/ is the problem. | ||
* Ideally I would fix this via the `options.packageFilter`, but that | ||
* for some reason is not working - possibly a bug in Jest. So I'm just | ||
* doing a simple replace here instead.) | ||
*/ | ||
function fixReactHookPaths(path) { | ||
const replacements = { | ||
'@react-hook/resize-observer/dist/module/index.js': '@react-hook/resize-observer/dist/main/index.js', | ||
'@react-hook/passive-layout-effect/dist/module/index.js': '@react-hook/passive-layout-effect/dist/main/index.js', | ||
'@react-hook/latest/dist/module/index.js': '@react-hook/latest/dist/main/index.js', | ||
} | ||
|
||
Object.keys(replacements).forEach(key => { | ||
path = path.replace(key, replacements[key]) | ||
}) | ||
|
||
return path | ||
} | ||
|
||
/** | ||
* https://jestjs.io/docs/configuration/#resolver-string | ||
*/ | ||
module.exports = (path, options) => { | ||
let result = options.defaultResolver(path, options) | ||
return fixReactHookPaths(result) | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -99,6 +99,6 @@ | |
"react" | ||
], | ||
"dependencies": { | ||
"react-hook-click-away": "^1.0.0" | ||
"@react-hook/resize-observer": "^1.2.6" | ||
} | ||
} |
Oops, something went wrong.