- 25 Nov, 2019 1 commit
-
-
Robert Knight authored
Previously only the _contents_ of modules were minified, but not the module infrastructure that Browserify adds around it. Given lots of modules, this adds up. Replace `uglifify` with a small wrapper around terser, the package that actually compresses the code, and use it to minify both the contents of modules and the generated wrapper code. Calling terser directly allows us to a) use the current version of it (uglifyify was stuck on Terser 3.x) and b) upgrade/configure/replace it more directly in future. One other change here is that minifying modules is now done _after_ the transform that replaces `if (process.env.NODE_ENV == ...)` checks with `if (true)` or `if (false)`. This enables dead-code removal to remove the logic entirely. This reduces the minified size of `sidebar.bundle.js` from 368 KB to 311 KB (-15%) and `annotator.bundle.js` from 170 KB to 152 KB (-12.7%). Some vendor bundles are smaller, others are unaffected because they were already fully minified. The total minified size of all bundles is reduced by ~7%.
-
- 21 Nov, 2019 22 commits
-
-
Kyle Keating authored
Rename the username to userid in selection module
-
Kyle Keating authored
The username was really the userid and was named incorrectly. Still allow username in the config to work in the meantime until its depreciated in LMS
-
Robert Knight authored
Convert SASS files to SASS modules
-
Robert Knight authored
-
Robert Knight authored
-
Robert Knight authored
Prepare SASS files for transition to SASS modules
-
Lyza Gardner authored
Update icons in `MarkdownEditor`; add Help Link
-
Lyza Danger Gardner authored
-
Robert Knight authored
Merge in recent changes to app styles.
-
Lyza Gardner authored
Extract `ShareLinks` component
-
Lyza Danger Gardner authored
-
Robert Knight authored
Fix conflicts in excerpt.scss
-
Robert Knight authored
Migrate .scss files to SASS modules using: ``` sass-migrator module --load-path=node_modules/ --migrate-deps src/styles/annotator/annotator.scss src/styles/sidebar/sidebar.scss ``` This was previously done for the lms app in https://github.com/hypothesis/lms/pull/1057
-
Robert Knight authored
This defines `u-*` classes which are used in various places.
-
Robert Knight authored
-
Robert Knight authored
Nested imports only support loading plain CSS when using SASS modules. Therefore move the bucket bar imports to the top level, but wrap the styles inside that module in `.annotator-frame` to ensure they take precedence over the CSS reset, which is the original reason for using a nested import.
-
Robert Knight authored
This module was used by multiple SASS entry points (annotator, sidebar) even though each mixin or class within it was either trivial or only actually used by one of the entry points. Moving the mixins to the individual entry points will make it easier to run the migrator.
-
Robert Knight authored
Fix margins on annotation body content causing content to be cropped
-
Lyza Danger Gardner authored
-
Robert Knight authored
In preparation for running the sass-migrator tool, hoist several imports from included SASS files up to the entry points at src/styles/{annotator/annotator.scss, sidebar/sidebar.scss}.
-
Robert Knight authored
This path was always wrong but happened not to break the build previously.
-
Robert Knight authored
Fix an issue where elements in the annotation body that were styled with margins, such as headings and block quotes, could cause the bottom of an excerpt to cropped. The issue was that margin collapsing [2] caused the margin to "leak" out of the excerpt's content `<div>` and push it vertically away from the outermost element of the excerpt. The `max-height` applied to the outermost element took into account the content's _height_ but not its vertical offset. The fix here is to make the excerpt content div a new block-formatting context [1] which ensures that any margins on elements inside the content are placed _inside_ the content element. There are various ways of doing this, but `display: inline-block` is backwards compatible down to IE 11. - Fix margin collapsing issue by making content a new block formatting context - Remove unused `excerpt__container` class and an incorrect comment about the excerpt class - Remove an unnecessary `test-name` attribute on the content element and use the class name to find it in tests instead - Add a note about some refactoring that can be done post SASS-module adoption [1] https://developer.mozilla.org/en-US/docs/Web/Guide/CSS/Block_formatting_context [2] https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Box_Model/Mastering_margin_collapsing Fixes #1518
-
- 20 Nov, 2019 14 commits
-
-
Lyza Gardner authored
Factor out some reusable CSS into mixins
-
Lyza Danger Gardner authored
Extract some reusable button styles, as well as some patterns for lists of linked icons and a "panel" pattern. It is likely organization of this will evolve as a pattern-library approach is implemented, but this avoids copy-pasta and tightens up consistency between uses.
-
dependabot-preview[bot] authored
-
dependabot-preview[bot] authored
Bumps [angular](https://github.com/angular/angular.js) from 1.7.8 to 1.7.9. **This update includes a security fix.** - [Release notes](https://github.com/angular/angular.js/releases) - [Changelog](https://github.com/angular/angular.js/blob/master/CHANGELOG.md) - [Commits](https://github.com/angular/angular.js/compare/v1.7.8...v1.7.9) Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
-
Robert Knight authored
Revert "Update core-js to current version"
-
Robert Knight authored
-
Lyza Gardner authored
Remove unused form and button classes
-
Lyza Gardner authored
Remove deprecated SCSS `$brand-color` color variable
-
Lyza Danger Gardner authored
-
Lyza Danger Gardner authored
Use `$brand` instead, which has the identical value
-
Robert Knight authored
Update core-js to current version
-
Robert Knight authored
Improve mobile UX of markdown editor and search input
-
Robert Knight authored
Convert excerpt to Preact (2/n)
-
Robert Knight authored
The prop name `overflowHysteresis` was frequently typo-d and is also misleading as the excerpt doesn't remember the history of the overflow value, it just uses it as a fixed threshold. Rename it to `overflowThreshold` instead. Also improve / simplify a few JSDoc comments per PR feedback.
-
- 19 Nov, 2019 3 commits
-
-
Kyle Keating authored
Warn in JSON-RPC server if message is dropped by origin filter
-
Lyza Gardner authored
Remove (some) deprecated SCSS color variables
-
Lyza Danger Gardner authored
`$color-cardinal` and `$gray-lightest` have no references in existing SCSS
-