diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml new file mode 100644 index 00000000..c763b3b9 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -0,0 +1,64 @@ +name: Bug report +description: File a bug report to help improve Readium CSS +labels: [] +type: "Bug" +body: + - type: markdown + attributes: + value: | + Thank you for filing a bug report! Please [search for existing issues](https://github.com/readium/css/issues?q=is:issue) before submitting. + - type: textarea + id: bug-description + attributes: + label: Describe the bug + description: Also, please let us know what your expectations were. + placeholder: A clear and concise description of what the bug is. + validations: + required: true + - type: textarea + id: bug-steps + attributes: + label: How to reproduce? + description: | + Step by step explanation to reproduce the issue in the Test App. + + If you can, drag and drop: + - the publication used to reproduce the problem, after zipping it. + - screenshots or a screencast showing the issue + + placeholder: | + 1. Open book X + 2. Go to chapter Y + 3. Swipe left twice + 4. See error + ... + validations: + required: true + - type: input + id: bug-readium-css-version + attributes: + label: Readium CSS version + description: What version of Readium CSS are you running? + validations: + required: true + - type: input + id: bug-platforms + attributes: + label: Platforms + description: On which platform(s) did you reproduce the problem? + validations: + required: true + - type: input + id: bug-browsers + attributes: + label: Browsers + description: On which browser(s) did you reproduce the problem? + validations: + required: true + - type: textarea + id: bug-additional + attributes: + label: Additional context + description: | + Share additional code showing how you use Readium, if relevant. Output logs are useful as well. + If you already went through the codebase to find the bug, you can explain your findings here. \ No newline at end of file diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 00000000..a49eab2f --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1 @@ +blank_issues_enabled: true \ No newline at end of file diff --git a/.github/issue_template.md b/.github/issue_template.md deleted file mode 100644 index 066b33e7..00000000 --- a/.github/issue_template.md +++ /dev/null @@ -1,38 +0,0 @@ -I'm submitting a [bug report | feature request | other] - -**Short description of the issue/suggestion:** - - - -**Steps to reproduce the issue/enhancement:** - -1. [First Step] -2. [Second Step] -3. [Other Steps...] - -**What is the expected behaviour?** - - - -**What is the current behaviour?** - - - -**Do you have screenshots, GIFs, demos or samples which demonstrate the problem or enhancement?** - -![image description](url) - -**What is the motivation / use case for changing the behaviour?** - - - -**Do you know which CSS modules (stylesheets) are impacted?** - - - -**Please tell us about your environment:** - -- Platform: [Android | iOS | Linux | MacOS | Windows | other] -- Browser / Rendering Engine: [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Chromium on Electron XX | Android Web View | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView | other] - -**Other information** (e.g. related issues, suggestions how to fix, links for us to have context) diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md deleted file mode 100644 index d0ea620c..00000000 --- a/.github/pull_request_template.md +++ /dev/null @@ -1,27 +0,0 @@ -**Please check if the PR fulfills these requirements:** - -(Add x between brackets to check.) - -- [ ] I’ve read [contributing guidelines](../contributing.md) -- [ ] I’m making this pull request against the develop branch -- [ ] I’ve updated from the develop branch before proposing this pull request -- [ ] I’ve tested the changes for bug fixes and/or features -- [ ] I’ve documented new code - -**What kind of change does this PR introduce?** (Bug fix, feature, docs update, other) - - - -**What is the current behaviour?** (You can also link to an open issue here) - - - -**What is the new behaviour?** - - - -**Does this PR introduce a breaking change?** (What changes might users need to make in their application due to this PR?) - - - -**Other information:** \ No newline at end of file diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index 020f3149..b7477d65 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -20,6 +20,7 @@ jobs: - uses: actions/checkout@v4 with: ref: ${{ github.head_ref }} + fetch-depth: 0 # Fetch complete git history - name: Use Node.js uses: actions/setup-node@v4 with: @@ -29,5 +30,5 @@ jobs: - run: npm run build --if-present - uses: stefanzweifel/git-auto-commit-action@v5 with: - file_pattern: "css/dist/**" + file_pattern: "css/dist/** package-lock.json" commit_message: Update dist \ No newline at end of file diff --git a/.nvmrc b/.nvmrc new file mode 100644 index 00000000..85aee5a5 --- /dev/null +++ b/.nvmrc @@ -0,0 +1 @@ +v20 \ No newline at end of file diff --git a/README.md b/README.md index 38f65400..4befa4ba 100644 --- a/README.md +++ b/README.md @@ -1,16 +1,15 @@ -# readium-css +# Readium CSS [![Readium Logo](https://readium.org/assets/logos/readium-logo.png)](https://readium.org) -A set of reference stylesheets for EPUB Reading Systems, starting with Readium 2. +A set of reference stylesheets for EPUB Reading Systems. Readium CSS provides styles for reflowable text: - paged and scrolled views; - a “patch” for HTML5 Suggested Rendering specific to publications (e.g. extra styles for hyphenation, breaks, etc.); - default styles for unstyled ebooks; -- reading modes (day, night, and sepia); -- themes; +- theming; - user settings; - a set of baselines and recommendations for accessibility, overrides, and internationalization. @@ -18,35 +17,36 @@ Readium CSS provides styles for reflowable text: BSD-3-Clause (http://opensource.org/licenses/BSD-3-Clause) -See [license.txt](https://github.com/readium/readium-css/blob/master/LICENSE). +See [license.txt](https://github.com/readium/css/blob/master/LICENSE). ## Scope of this project The primary goal of Readium CSS is to provide Reading System implementers with reliable and modern styles for reflowable EPUB 2 and EPUB 3 files. In addition, it should provide good interoperability in the existing ecosystem, while not overriding authors’ styles unless strictly necessary. -Readium CSS stylesheets were not designed and should not be used for fixed-layout EPUB, nor other file formats like FB2, PRC, Mobi, TEI, etc. Works in progress like Web Publications or Portable Web Publications are also out of scope. +Readium CSS stylesheets were not designed and should not be used for fixed-layout EPUB, nor other file formats like FB2, PRC, Mobi, TEI, etc. Some issues, which may be raised during development, will be documented so that they can serve as a reference for revisions of the EPUB specification, and even future specifications. -## Testing +## Implementations -An [iOS test app](https://github.com/readium/r2-testapp-swift) for the Swift implementation of Readium 2 is using Readium CSS and can be [downloaded on the App Store](https://itunes.apple.com/us/app/r2-reader/id1363963230?mt=8). +Readium CSS is implemented in the [Readium Mobile](https://github.com/readium/mobile) and [Readium Web](https://github.com/readium/web) projects. -An [Android test app](https://github.com/readium/r2-testapp-kotlin) for the Kotlin implementation of Readium 2 is using Readium CSS. Stable builds are [available on Google Play](https://play.google.com/store/apps/details?id=org.readium.r2reader). To follow the development of this app, [join the beta channel](https://play.google.com/apps/testing/org.readium.r2reader). +You will find it in: -The Readium Desktop app is using Readium CSS and [is available for Linux, MacOS and Windows](https://github.com/edrlab/readium-desktop/releases). +- [ts-toolkit](https://github.com/readium/ts-toolkit) +- [swift-toolkit](https://github.com/readium/swift-toolkit) +- [kotlin-toolkit](https://github.com/readium/kotlin-toolkit) -You can also use the [webpub manifest prototype](https://github.com/HadrienGardeur/webpub-manifest/tree/gh-pages/examples/paged-viewer) with the [RS-streamer-js](https://github.com/edrlab/r2-streamer-js) in a local development environment. Please note you’ll have to manually inject stylesheets and apply settings via the console, or design and code scripts if you want a GUI (user settings menu). +External use include: -## Other known implementations - -There is no external implementation of Readium CSS so far. - -Consequently, if you are encountering rendering issues with Readium (iOS apps, Android apps, or the Readium Chrome App), please report them on the [github section dedicated to the proper Readium project](https://github.com/readium) (readium-js, readium-shared-js, readium-sdk, etc.). +- [Thorium Desktop](https://github.com/edrlab/thorium-reader) +- [Thorium Web](https://github.com/edrlab/thorium-web) +- [Zotero](https://github.com/zotero/reader) +- [Vital Source](https://www.vitalsource.com/) ## Development -Active development is pulled in branch `develop` first, and then made available in the main branch when sufficiently tested and deemed stable. +Active development is pulled in branch `develop`. ### Init @@ -88,4 +88,4 @@ npm run test:approve Documentation [can be accessed in docs](docs). -[You can alternatively download it as an EPUB file](https://github.com/readium/readium-css/raw/master/docs/ReadiumCSS_docs.epub). \ No newline at end of file +[You can alternatively download it as an EPUB file](https://github.com/readium/css/raw/master/docs/ReadiumCSS_docs.epub). diff --git a/_includes/toc.html b/_includes/toc.html index 8bbdfac7..35a77f48 100644 --- a/_includes/toc.html +++ b/_includes/toc.html @@ -10,8 +10,10 @@
  • Defaults
  • Typefaces and font-stacks
  • Open Source and Libre Fonts We Can Recommend
  • +
  • Variable fonts
  • +
  • Using custom fonts with Readium CSS
  • User Overrides’ Classification
  • -
  • User Settings, Reading Modes and Themes
  • +
  • User Settings and Themes
  • Baseline for a11y-related user settings
  • Recommendations for User Settings Management
  • User Preferences’ insights
  • @@ -27,5 +29,6 @@
  • CSS Performance Hacks
  • i18n glossary
  • Features that were considered but not implemented
  • +
  • Migration Guide
  • \ No newline at end of file diff --git a/backstop.json b/backstop.json index 4fa72fe7..526b1699 100644 --- a/backstop.json +++ b/backstop.json @@ -1,11 +1,6 @@ { "id": "ReadiumCSS", "viewports": [ - { - "label": "phone", - "width": 375, - "height": 667 - }, { "label": "tablet", "width": 1024, @@ -49,8 +44,15 @@ "misMatchThreshold" : 0.1 }, { - "label": "Page margins pref", - "url": "http://localhost:8000/tests/margins.html", + "label": "3 columns pref", + "url": "http://localhost:8000/tests/cols-3.html", + "delay": 0, + "selectors": ["viewport"], + "misMatchThreshold" : 0.1 + }, + { + "label": "Line length pref", + "url": "http://localhost:8000/tests/line-length.html", "delay": 0, "selectors": ["viewport"], "misMatchThreshold" : 0.1 @@ -70,22 +72,29 @@ "misMatchThreshold" : 0.1 }, { - "label": "Day mode pref", - "url": "http://localhost:8000/tests/day.html", + "label": "Scroll padding pref", + "url": "http://localhost:8000/tests/scroll-padding.html", "delay": 0, "selectors": ["document"], "misMatchThreshold" : 0.1 }, { - "label": "Sepia mode pref", - "url": "http://localhost:8000/tests/sepia.html", + "label": "Default colors pref", + "url": "http://localhost:8000/tests/default-colors.html", "delay": 0, "selectors": ["document"], "misMatchThreshold" : 0.1 }, { - "label": "Night mode pref", - "url": "http://localhost:8000/tests/night.html", + "label": "Default custom colors pref", + "url": "http://localhost:8000/tests/default-custom-colors.html", + "delay": 0, + "selectors": ["document"], + "misMatchThreshold" : 0.1 + }, + { + "label": "Theming (Reading System)", + "url": "http://localhost:8000/tests/theming.html", "delay": 0, "selectors": ["document"], "misMatchThreshold" : 0.1 @@ -93,7 +102,7 @@ { "label": "Font family pref", "url": "http://localhost:8000/tests/font-family.html", - "delay": 0, + "delay": 500, "selectors": ["document"], "misMatchThreshold" : 0.1 }, @@ -104,6 +113,20 @@ "selectors": ["document"], "misMatchThreshold" : 0.1 }, + { + "label": "Deprecated font size pref", + "url": "http://localhost:8000/tests/font-size-deprecated.html", + "delay": 0, + "selectors": ["document"], + "misMatchThreshold" : 0.1 + }, + { + "label": "Font size normalize pref", + "url": "http://localhost:8000/tests/font-size-normalize.html", + "delay": 0, + "selectors": ["document"], + "misMatchThreshold" : 0.1 + }, { "label": "Type scale pref", "url": "http://localhost:8000/tests/type-scale.html", @@ -177,7 +200,7 @@ { "label": "Accessibility font pref", "url": "http://localhost:8000/tests/a11y-font.html", - "delay": 200, + "delay": 500, "selectors": ["document"], "misMatchThreshold" : 0.1 }, @@ -191,7 +214,7 @@ { "label": "Accessibility custom pref", "url": "http://localhost:8000/tests/a11y-custom.html", - "delay": 200, + "delay": 500, "selectors": ["document"], "misMatchThreshold" : 0.1 }, @@ -201,6 +224,55 @@ "delay": 0, "selectors": ["document"], "misMatchThreshold" : 0.1 + }, + { + "label": "Font optical sizing pref", + "url": "http://localhost:8000/tests/font-optical-sizing.html", + "delay": 0, + "selectors": ["document"], + "misMatchThreshold" : 0.1 + }, + { + "label": "Font weight pref", + "url": "http://localhost:8000/tests/font-weight.html", + "delay": 500, + "selectors": ["document"], + "misMatchThreshold" : 0.1 + }, + { + "label": "Font width Keyword pref", + "url": "http://localhost:8000/tests/font-width-keyword.html", + "delay": 500, + "selectors": ["document"], + "misMatchThreshold" : 0.1 + }, + { + "label": "Font width Percentage pref", + "url": "http://localhost:8000/tests/font-width-percentage.html", + "delay": 500, + "selectors": ["document"], + "misMatchThreshold" : 0.1 + }, + { + "label": "Blend Filter pref", + "url": "http://localhost:8000/tests/blend-filter.html", + "delay": 0, + "selectors": ["document"], + "misMatchThreshold" : 0.1 + }, + { + "label": "Darken Filter pref", + "url": "http://localhost:8000/tests/darken-filter.html", + "delay": 0, + "selectors": ["document"], + "misMatchThreshold" : 0.1 + }, + { + "label": "Invert Filter pref", + "url": "http://localhost:8000/tests/invert-filter.html", + "delay": 0, + "selectors": ["document"], + "misMatchThreshold" : 0.1 } ], "paths": { diff --git a/contributing.md b/contributing.md index 60209f51..b6e486f9 100644 --- a/contributing.md +++ b/contributing.md @@ -1,248 +1,15 @@ -# Contributing to Readium CSS +# How to contribute First and foremost, thanks for your interest! 👍 -The following is a set of guidelines for contributing to the Readium CSS project, hosted in the [Readium](https://github.com/readium) Organization on Github. These are just guidelines, not rules, so feel free to propose changes to this document in a pull request. +We welcome many kind of contributions such as improving the documentation, submitting bug reports and feature requests, or writing code. -## Table of contents +## Contributor License Agreement -1. [Design Principles](#design-principles) -2. [Testing](#testing) -3. [Coding Standards](#coding-standards) -4. [How Can I Contribute?](#how-can-i-contribute) - + [Reporting Bugs](#reporting-bugs) - + [Suggesting Enhancements](#suggesting-enhancements) - + [Your First Code Contribution](#your-first-code-contribution) - + [Pull Requests](#pull-requests) -5. [Roadmap](#roadmap) +By contributing to this project, you agree to license your contribution under the [BSD-3-Clause license](LICENSE). -## Design Principles +## Writing New Code -Readium CSS has been design following 4 principles: +Please follow the patterns of existing code and ensure that your new features are testable (`tests`) and well-documented in `docs`. -1. **Modularity:** Readium CSS is not a monolithic stylesheet but a set of modules; -2. **Separation of Reading System’s Concerns:** those modules are task-oriented e.g. paginate, apply default styles, intercept styles for user settings, apply a reading mode or user setting, etc.; -3. **Daisy-chainability:** those modules can be loaded and daisy-chained (cascade), depending on conditions; -4. **Customization:** modules can be customized either before or during runtime (CSS variables). - -Please keep those principles in mind before making a pull request. If you have any doubt, please feel free to contact [maintainers](mailto:readium-css@edrlab.org). - -## Testing - -Since Readium CSS and Readium 2 are still in their early days, there is no other way than DYI-testing right now. - -You can either: - -1. try implementing it in an existing Reading System; -2. use the [webpub manifest prototype](https://github.com/HadrienGardeur/webpub-manifest/tree/gh-pages/examples/paged-viewer). - -In any case, you have to manually inject stylesheets and apply settings via the console, or design and code scripts if you want a GUI (user settings menu). - -You can use the [R2-streamer-js](https://github.com/edrlab/r2-streamer-js) to manage EPUB files if needed. - -## Coding Standards - -The following guidelines are aimed at existing or newly-created stylesheets for Readium CSS. - -### General Rules - -- Indent by 2 spaces (or a tab which is equal to 2 spaces). -- Use multiline: one property and value per line. -- Add a space after a property’s colon (e.g. `display: block`). -- End all lines with a semi-colon. -- For multiple, comma-separated selectors, try grouping them in a logical fashion (e.g. putting headings together). -- Attribute selectors, like `input[type="text"]` should always wrap the attribute's value in double quotes. -- Don’t use classes, style elements. -- Only use `!important` when a style must be applied at any cost necessary. -- Try using prefixed-properties which are necessary, including `-epub-properties` (check the [EPUB 3.2 spec](https://w3c.github.io/publ-epub-revision/epub32/spec/epub-contentdocs.html#sec-css-prefixed) for a complete list). - -### Stylesheet Header - -Every stylesheet must contain a header using the following template: - -``` -/* Readium CSS - Name of the stylesheet - - Description i.e. which task the stylesheet is trying to accomplish - - Repo: https://github.com/readium/readium-css */ -``` - -### Custom Properties (variables) - -We’re using custom properties, also known as CSS variables, to make Readium CSS customizable. See the `CSS-api.md` file in docs for a complete list. - -We’re currently using the two following prefix: - -- `--RS__` for Reading System variables; -- `--USER__` for user settings. - -The variable itself must use camelCase (e.g. `--RS__textColor`, and `--USER__fontSize`). - -Of course all values don’t have to be variables, variables should be used if: - -- it allows implementers to customize Reading System styles or themes; -- it is likely to be updated on runtime (user setting). - -### Cascade and Inheritance - -Readium CSS is leveraging the cascade and inheritance, which implies authors’ stylesheets are part of the cascade. - -The order of priority we must emulate is the following: - -1. transition declarations; -2. important user agent declarations; -3. important user declarations; -4. important author declarations; -5. animation declarations; -6. normal author declarations; -7. normal user declarations; -8. normal user agent declarations. - -In other words, we’re following the priority of constituencies whenever possible: - -``` -User > Author > User Agent -``` - -This applies to the custom properties as well: - -``` ---USER__var > --RS__var -``` - -If possible, user settings must be inherited from the `--USER__variable` set on `:root`. This obviously can’t be done for all user settings as it depends on the scope (the elements targeted). - -User settings must also abide by [these recommendations](https://readium.org/readium-css/docs/CSS14-user_settings_recs.html). - -## How Can I Contribute? - -### Reporting Bugs - -First and foremost, check if your issue has already been reported (don’t forget to check closed issues too). If it has, add a comment to the existing issue instead of opening a new one. - -Before opening any issue… - -- **Ensure your EPUB is valid.** Always validate your EPUB against [EPUBCheck](https://github.com/w3c/epubcheck). If there are errors or warnings, please fix those before submitting an issue. -- **Create an isolated and reproducible test case.** Be sure the problem exists in Readium CSS (try your HTML in the browser). Try providing a [reduced test case](https://css-tricks.com/reduced-test-cases/). -- **Share as much information as possible.** See below. - -#### Submitting a Good Bug Report - -Explain the problem and include additional details to help maintainers reproduce the problem: - -- Use a clear and descriptive title for the issue to identify the problem. -- Tell which platforms or browsers are impacted. -- Describe the exact steps to reproduce the problem in as many details as possible. -- Provide specific examples to demonstrate the steps. Include links to files or GitHub projects, or copy/pasteable snippets, which you use in those examples. If you're providing snippets in the issue, use Markdown code blocks. -- Describe the behavior you observed after following the steps and point out what exactly is the problem with that behavior. -- Explain which behavior you expected to see instead and why. -- Include screenshots and/or animated GIFs which show you following the described steps and clearly demonstrate the problem. -- If you’ve fixed the issue by yourself, tell us how you did it (snippet in a Markdown code block). - -#### Template for Submitting Bug Reports - -``` -I'm submitting a… - -- [x] bug report -- [ ] feature request -- [ ] other - -**Short description of the issue/suggestion:** - -**Steps to reproduce the issue/enhancement:** - -1. [First Step] -2. [Second Step] -3. [Other Steps...] - -**What is the expected behaviour?** - -**What is the current behaviour?** - -**Do you have screenshots, GIFs, demos or samples which demonstrate the problem or enhancement?** - -![image description](url) - -**What is the motivation / use case for changing the behaviour?** - -**Do you know which CSS modules (stylesheets) are impacted?** - -**Please tell us about your environment:** - -- Platform: [Android | iOS | Linux | MacOS | Windows | other] -- Browser / Rendering Engine: [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Chromium on Electron XX | Android Web View | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView | other] - -**Other information** (e.g. related issues, suggestions how to fix, links for us to have context) -``` - -### Suggesting Enhancements - -First and foremost, check if those enhancements have already been suggested (check issues) or addressed (check pull requests). - -#### Submitting a Good Enhancement Suggestion - -- Use a clear and descriptive title for the issue to identify the suggestion. -- Provide a step-by-step description of the suggested enhancement in as many details as possible. -- Provide specific examples to demonstrate the steps. Include copy/pasteable snippets which you use in those examples, as Markdown code blocks. -- Include screenshots and/or animated GIFs which help you demonstrate the steps or point out the part of Readium CSS which the suggestion is related to. -- Explain why this enhancement would be useful to most users, the problems it solves as regards design, UX, etc. - -#### Template for Suggesting an Enhancement - -``` -I'm submitting a… - -- [ ] bug report -- [x] feature request -- [ ] other - -**Short description of the issue/suggestion:** - -**Steps to reproduce the issue/enhancement:** - -1. [First Step] -2. [Second Step] -3. [Other Steps...] - -**What is the expected behaviour?** - -**What is the current behaviour?** - -**Do you have screenshots, GIFs, demos or samples which demonstrate the problem or enhancement?** - -![image description](url) - -**What is the motivation / use case for changing the behaviour?** - -**Do you know which CSS modules (stylesheets) are impacted?** - -**Please tell us about your environment:** - -- Platform: [Android | iOS | Linux | MacOS | Windows | other] -- Browser / Rendering Engine: [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Chromium on Electron XX | Android Web View | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView | other] - -**Other information** (e.g. related issues, suggestions how to fix, links for us to have context) -``` - -### Your First Code Contribution - -Unsure where to begin contributing to the Readium CSS Project? You can start by looking through the `feedback-required` and/or `low-hanging fruit` issues. - -Then fork the repo, create a branch named after the issue you’re trying to solve, and implement your modifications. - -If needed, do not hesitate to ask questions. We’re here to help. - -We’ll finally review your pull request to check if everything is OK. - -### Pull Requests - -- Test your code (see [platform support](https://github.com/readium/readium-css/wiki/Platform-Support) in the Wiki). -- Pull requests should **always** be created against the develop branch – never the master. -- Please update from the develop branch before proposing a pull request so that we don’t have to deal with conflicts. -- Use a clear and descriptive title. -- List all fixes and enhancements the pull request provides. -- Include screenshots and/or animated GIF whenever possible – no need to do that for correcting typos in docs for instance. -- Document new code. \ No newline at end of file +New features should be implemented as their own modules and imported in the stylesheets where it makes more sense (`-before`, `-default`, `-after`). If you are unsure where it should go, simply mention it in the Pull Request. \ No newline at end of file diff --git a/css/ReadMe.md b/css/ReadMe.md index 45c165c7..6a75d1e8 100644 --- a/css/ReadMe.md +++ b/css/ReadMe.md @@ -5,8 +5,7 @@ Readium CSS is a set of reference stylesheets for EPUB Reading Systems. It provi - a CSS normalize for EPUB contents; - paged and scrolled views; - default styles; -- reading modes (night, sepia, etc.); -- themes; +- theming; - user settings. **Note:** Readium CSS stylesheets were not designed and should not be used for fixed-layout EPUB, nor other file formats like FB2, PRC, Mobi, TEI, etc. @@ -42,46 +41,23 @@ By default, we inject all stylesheets on load and rely on custom properties (a.k ## Customize -ReadiumCSS ships with a `ReadiumCSS-config.css` file you can use to customize it a little bit. It allows implementers to: +ReadiumCSS ships with a `ReadiumCSS-config.css` file you can use to customize it a little bit. It allows implementers to choose selectors for the user settings’ flags. -1. define in which conditions the auto pagination model is used; -2. choose selectors for the user settings’ flags. - -In order to provide this customization, we use custom media and custom selectors, which will hopefully become [standards implemented at some point](https://drafts.csswg.org/css-extensions/), but require PostCSS at the moment. Consequently, you’ll have to rebuild all `dist` stylesheets if you’re changing this file. - -### Auto pagination model - -The auto pagination model switches from 1 to 2 columns, and vice versa, when the conditions defined in `ReadiumCSS-config.css` are met. Further details about this model can be found in [“Injection and pagination” doc](../docs/CSS03-injection_and_pagination.md). - -On desktop, `--responsive-columns` is the `min-width` at which the model must be used. Default is `60em`, a relative unit since it is responsive by default and will switch depending on the window’s dimensions and the font size. - -Should you want it never or always applied, you can either define a `min-width` large or small enough, or remove the media queries entirely in `ReadiumCSS-pagination.css` and `ReadiumCSS-colNumber_pref.css`. - -On mobile, `--min-device-columns` and `--max-device-columns` is the range of (minimum and maximum) device widths in which the model must be used. We are forcing the orientation in `landscape`. - -We recommend not trying to apply it in portrait orientation because 2 columns will provide users with quite a terrible reading experience in this configuration. - -Those custom medias may be extended at some point, depending on implementers’ feedbacks and issues. +In order to provide this customization, we use custom selectors, which will hopefully become [standards implemented at some point](https://drafts.csswg.org/css-extensions/), but require PostCSS at the moment. Consequently, you’ll have to rebuild all `dist` stylesheets if you’re changing this file. ### Flags for user settings -By default, we are using flags in the form of CSS variables to manage reading modes and user settings. But you might want to customize those flags in order to use custom attributes (`data-*`) or good old CSS classes. +By default, we are using flags in the form of CSS variables to manage user settings. But you might want to customize those flags in order to use custom attributes (`data-*`) or good old CSS classes. A complete list of flags can be found in the [User preferences doc](../docs/CSS12-user_prefs.md). -As an example, if you want to use a CSS class for night mode, it could look like: - -``` -@custom-selector :--night-mode .night-mode; -``` - -And if you want to use custom attributes for advanced settings, it could look like: +As an example, if you want to use custom attributes for advanced settings, it could look like: ``` @custom-selector :--advanced-settings [data-settings="advanced"]; ``` -Both would then have to be appended to `html` at runtime. +It would then have to be appended to `html` at runtime. Once again, you must rebuild `dist` stylesheets. @@ -94,7 +70,6 @@ In the `css/src` folder, you’ll find all the needed stylesheets you will proce ``` @import "../ReadiumCSS-config.css"; @import "modules/ReadiumCSS-base.css"; -@import "modules/ReadiumCSS-day_mode.css"; @import "modules/ReadiumCSS-fonts.css"; @import "modules/ReadiumCSS-html5patch.css"; @import "modules/ReadiumCSS-safeguards.css"; @@ -175,6 +150,8 @@ To remove a variable: var root = document.documentElement || document.getElementById("iframe-wrapper").contentWindow.document.documentElement; root.style.removeProperty("--USER__var"); + +// or root.style.setProperty("--USER__var", ""); ``` Please note you must implement a fallback strategy if you want to support Internet Explorer 11 and early versions of Microsoft Edge. @@ -191,17 +168,19 @@ root.style.setProperty("--USER__bodyHyphens", "auto"); Of course this example is simplistic. You could for instance create an helper to set multiple properties at once. -#### Changing the type scale +## Create Themes -You might want to change the type scale in order to adjust the `font-size` of all elements to the size of the screen and the global `font-size` set by the user. It can indeed help solve overflow issues for long words in headings, ridiculously large sizes, etc. +In Readium CSS model, themes are a set of user settings you can store and retrieve. Add the properties to `html` and you get a theme. -``` -root.style.setProperty("--USER__advancedSettings", "readium-advanced-on"); -root.style.setProperty("--USER__typeScale", "1.067"); -``` +Depending on the prefix you are using, `--RS__` or `--USER__`, your theme will override the publisher’s styles or not. The rule being `USER > PUBLISHER > RS`. -## Create Themes +Check the [User Preferences doc](../docs/CSS12-user_prefs.md) for a list of available user variables. -In this model, themes are a set of user settings you can store and retrieve. Add the properties to `html` and you get a theme. +You can also retrieve ReadiumCSS presets for font-stacks, colors and pagination by adding it as a package, then importing its exposed json files. For instance in JS/TS: + +``` +import defaultColors from "readium-css/css/vars/colors.json"; -Check the [User Preferences doc](../docs/CSS12-user_prefs.md) for a list of available user variables. \ No newline at end of file +const backgroundColor = defaultColors.RS__backgroundColor; +const textColor = defaultColors.RS__color; +``` \ No newline at end of file diff --git a/css/ReadiumCSS-config.css b/css/ReadiumCSS-config.css index 38f6b951..891d3634 100644 --- a/css/ReadiumCSS-config.css +++ b/css/ReadiumCSS-config.css @@ -1,25 +1,9 @@ /* Readium CSS Config module - A file allowing implementers to customize flags for reading modes, - user settings, etc. + A file allowing implementers to customize flags for user settings, etc. - Repo: https://github.com/readium/readium-css */ - -/* Custom medias - Syntax: @custom-media --variable (prop: value) */ - -/* Responsive columns - The minimum width for which responsive columns (2 -> 1 and vice versa, - depending on the current font-size) must be enabled */ -@custom-media --responsive-columns (min-width: 60em); - -/* Mobile columns - The minimum and maximum width for mobile devices. - We’re forcing the landscape orientation by default, - and must still investigate large tablets (iPad Pro, Surface Pro 3, etc.). */ -@custom-media --min-device-columns (min-device-width: 36em); -@custom-media --max-device-columns (max-device-width: 47em); + Repo: https://github.com/readium/css */ /* Custom selectors Syntax: @custom-selector :--variable selector @@ -30,19 +14,23 @@ @custom-selector :--paged-view [style*="readium-paged-on"]; @custom-selector :--scroll-view [style*="readium-scroll-on"]; -/* Font-family override */ -@custom-selector :--font-override [style*="readium-font-on"]; +/* Disabling the new implementation for font-size */ +@custom-selector :--deprecated-font-size [style*="readium-deprecatedFontSize-on"]; -/* Advanced settings */ -@custom-selector :--advanced-settings [style*="readium-advanced-on"]; - -/* Reading Modes */ -@custom-selector :--sepia-mode [style*="readium-sepia-on"]; -@custom-selector :--night-mode [style*="readium-night-on"]; +/* Font-size normalization for engines that don’t support zoom */ +@custom-selector :--fs-normalize [style*="readium-normalize-on"]; /* Filters (images) */ +@custom-selector :--blend-filter [style*="readium-blend-on"]; @custom-selector :--darken-filter [style*="readium-darken-on"]; @custom-selector :--invert-filter [style*="readium-invert-on"]; +@custom-selector :--invert-gaiji [style*="readium-invertGaiji-on"]; + +/* Disabling pagination for vertical writing */ +@custom-selector :--no-vertical-pagination [style*="readium-noVerticalPagination-on"]; + +/* Disabling overflow */ +@custom-selector :--no-overflow [style*="readium-noOverflow-on"]; /* Hiding ruby */ @custom-selector :--no-ruby [style*="readium-noRuby-on"]; @@ -50,9 +38,14 @@ /* Accessibility normalization */ @custom-selector :--a11y-normalize [style*="readium-a11y-on"]; -/* Accessibility font. You can add selectors, using “, ” as a separator, if you have multiple fonts */ -@custom-selector :--a11y-font [style*="AccessibleDfA"], [style*="IA Writer Duospace"]; - /* Direction i.e. ltr and rtl */ @custom-selector :--ltr [dir="ltr"]; -@custom-selector :--rtl [dir="rtl"]; \ No newline at end of file +@custom-selector :--rtl [dir="rtl"]; + +/* Patch for iOS and iPadOS */ +@custom-selector :--iOS-patch [style*="readium-iOSPatch-on"]; +@custom-selector :--ipadOS-patch [style*="readium-iPadOSPatch-on"]; + +/* Experimental/Feature flags */ +@custom-selector :--experimental-zoom [style*="readium-experimentalZoom-on"]; +@custom-selector :--experimental-header-filtering [style*="readium-experimentalHeaderFiltering-on"]; \ No newline at end of file diff --git a/css/demo/css/ReadiumCSS-after.css b/css/demo/css/ReadiumCSS-after.css deleted file mode 100644 index 5f8c4a29..00000000 --- a/css/demo/css/ReadiumCSS-after.css +++ /dev/null @@ -1,903 +0,0 @@ -/* Readium CSS - Config module - - A file allowing implementers to customize flags for reading modes, - user settings, etc. - - Repo: https://github.com/readium/readium-css */ - -/* Custom medias - Syntax: @custom-media --variable (prop: value) */ - -/* Responsive columns - The minimum width for which responsive columns (2 -> 1 and vice versa, - depending on the current font-size) must be enabled */ - -/* Mobile columns - The minimum and maximum width for mobile devices. - We’re forcing the landscape orientation by default, - and must still investigate large tablets (iPad Pro, Surface Pro 3, etc.). */ - -/* Custom selectors - Syntax: @custom-selector :--variable selector - The selectors you will use for flags/switches - You can alternatively use classes or custom data-* attributes */ - -/* User view = paged | scrolled */ - -/* Font-family override */ - -/* Advanced settings */ - -/* Reading Modes */ - -/* Filters (images) */ - -/* Accessibility normalization */ - -/* Accessibility font. You can add selectors, using “, ” as a separator, if you have multiple fonts */ - -/* Direction i.e. ltr and rtl */ - -/* Readium CSS - Pagination module - - A set of styles to paginate ePublications - - Repo: https://github.com/readium/readium-css */ - -/* Config */ - -/* Columns are responsive by default, even if column-width is set in pixels, - which means two-page spread will switch to single page depending on current font-size. - If you want more control, I’m afraid you’ll have to update colWidth/colGap dynamically, - which is how a significant amount of RS do at the moment. */ - -/* Default for smartphone portrait (small screens) */ - -:root { - /* Your columns’ width floor */ - --RS__colWidth: 45em; /* The width at which we’ll switch to 2 columns by default. PS: you can’t set it in rem */ - - /* Ideal number of columns (depending on columns’ width floor) */ - --RS__colCount: 1; - - /* Gap between columns (in pixels so that it won’t resize with font-size) */ - --RS__colGap: 0; - - /* Optimal line-length (rem will take :root font-size into account, whatever the body’s font-size) */ - --RS__maxLineLength: 40rem; - - /* Default page horizontal margins (in pixels so that it won’t resize with font-size) */ - --RS__pageGutter: 20px; /* See if colGap and pageGutter can be the same var */ -} - -/* Reset page margins for Forward compatibility */ - -@page { - margin: 0 !important; -} - -/* :root selector has same specificity as a class i.e. 0010 - We might have to change that to html / context - -> https://css-tricks.com/almanac/selectors/r/root/ */ - -:root { - - /* In case you use left position to scroll, can be removed if using transform: translateX() */ - position: relative; - - -webkit-column-width: var(--RS__colWidth); - -moz-column-width: var(--RS__colWidth); - column-width: var(--RS__colWidth); - - /* Init pagination */ - /* TODO: document columns’ logic cos it might feel weird at first */ - -webkit-column-count: var(--RS__colCount); - -moz-column-count: var(--RS__colCount); - column-count: var(--RS__colCount); - - -webkit-column-gap: var(--RS__colGap); - -moz-column-gap: var(--RS__colGap); - column-gap: var(--RS__colGap); - - /* Default is balance and we want columns to be filled entirely (100vh) */ - -moz-column-fill: auto; - column-fill: auto; - width: 100%; - height: 100vh; - max-width: 100%; - max-height: 100vh; - min-width: 100%; - min-height: 100vh; - padding: 0 !important; - margin: 0 !important; - - /* Column size will depend on this if we want to make it responsive */ - font-size: 100% !important; - - -webkit-text-size-adjust: 100%; - - /* Switch to newer box model (not inherited by authors’ styles) */ - box-sizing: border-box; - - /* Fix bug for older Chrome */ - -webkit-perspective: 1; - /* Prevents options pop-up when long tap in webkit */ - -webkit-touch-callout: none; -} - -body { - /* overflow: hidden; bugfix: contents won’t paginate in Firefox and one sample in Safari */ - width: 100%; - - /* Limit line-length but we have to reset when 2 columns and control the viewport. - By using max-width + margin auto, margins will shrink when font-size increases, - which is what would be expected in terms of typography. */ - max-width: var(--RS__maxLineLength) !important; - padding: 0 var(--RS__pageGutter) !important; - margin: 0 auto !important; - - /* We need a minimum padding on body so that descandants/ascendants in italic/script are not cut-off. - Drawback: we have to use border-box so that it doesn’t screw the box model, - which means it impacts colWidth and max-width */ - box-sizing: border-box; -} - -/* We’ll now redefine margins and columns depending on the minimum width available - The goal is having the simplest model possible and avoid targeting devices */ - -/* Smartphone landscape */ - -@media screen and (min-width: 35em) { - :root { - --RS__pageGutter: 30px; - } -} - -/* Tablet portrait */ - -@media screen and (min-width: 45em) { - :root { - --RS__pageGutter: 40px; - } -} - -/* Desktop + tablet large */ - -/* We get the previous settings, we just change the margins */ - -@media screen and (min-width: 75em) { - :root { - --RS__pageGutter: 50px; - } -} - -/* At this point (80em or so), constraining line length must be done at the web view/iframe level, or by limiting the size of :root itself */ - -/* Responsive columns */ - -@media screen and (min-width: 60em), screen and (min-device-width: 36em) and (max-device-width: 47em) and (orientation: landscape) { - :root { - /* The size at which we want 2 columns to switch to 1 (depending on font-size) */ - --RS__colWidth: 20em; /* 20 * 16 = 320px but 20 * 28 = 560px so it will switch to 1 col @ 175% font-size (user-setting) on an iPad */ - /* We constrain to 2 columns so that we can never get 3 or 4, etc. */ - --RS__colCount: 2; - --RS__maxLineLength: 39.99rem; /* If we don’t use this, colNumber user setting won’t work in Safari… */ - } -} - -/* Readium CSS - Scroll module - - A set of styles to scroll ePublications - This module overrides pagination - - Repo: https://github.com/readium/readium-css */ - -:root[style*="readium-scroll-on"] { - - /* Reset columns, auto + auto = columns can’t be created */ - -webkit-columns: auto auto !important; - -moz-columns: auto auto !important; - columns: auto auto !important; - width: auto !important; - height: auto !important; - max-width: none !important; - max-height: none !important; - /* Reset html size so that the user can scroll */ - min-width: 0 !important; - min-height: 0 !important; -} - -/* Make sure line-length is limited in all configs */ - -:root[style*="readium-scroll-on"] body { - --RS__maxLineLength: 40rem !important; -} - -/* Scroll mode horizontal */ - -/* Vertical writing needs body height set */ - -/* Do we add a top/bottom margin for body in vertical scroll or not? */ - -/* Readium CSS - Default highlights - - A stylesheet for user highlights - - Repo: https://github.com/readium/readium-css */ - -/* User Highlights */ - -.readiumCSS-yellow-highlight { - background-color: rgba(255, 255, 0, 0.5); -} - -.readiumCSS-green-highlight { - background-color: rgba(0, 255, 0, 0.5); -} - -.readiumCSS-orange-highlight { - background-color: rgba(255, 165, 0, 0.5); -} - -.readiumCSS-pink-highlight { - background-color: rgba(255, 105, 180, 0.5); -} - -/* Media overlays */ - -.readiumCSS-mo-active-default { - color: black !important; - background-color: yellow !important; -} - -/* Readium CSS - Night mode - - A preset theme for night mode - - Repo: https://github.com/readium/readium-css */ - -/* CONFIG */ - -/* [style*="--USER__appearance"] can be used to increase specificity but performance hit */ - -:root[style*="readium-night-on"] { - --RS__backgroundColor: #000000; - --RS__textColor: #FEFEFE; - - --RS__linkColor: #63caff; - --RS__visitedColor: #0099E5; - - /* This can be customized but initial will re-use default value of the browser */ - --RS__selectionBackgroundColor: #b4d8fe; - --RS__selectionTextColor: inherit; -} - -/* we don’t need to redeclare bg-color and color for :root since we will inherit and update from day/default mode */ - -:root[style*="readium-night-on"] *:not(a) { - color: inherit !important; - background-color: transparent !important; - border-color: currentColor !important; -} - -:root[style*="readium-night-on"] svg text { - fill: currentColor !important; - stroke: none !important; -} - -:root[style*="readium-night-on"] a:link, -:root[style*="readium-night-on"] a:link * { - color: var(--RS__linkColor) !important; -} - -:root[style*="readium-night-on"] a:visited, -:root[style*="readium-night-on"] a:visited * { - color: var(--RS__visitedColor) !important; -} - -:root[style*="readium-night-on"] img[class*="gaiji"], -:root[style*="readium-night-on"] *[epub\:type~="titlepage"] img:only-child { - -webkit-filter: invert(100%); - filter: invert(100%); -} - -/* Darken all images on user’s demand */ - -:root[style*="readium-night-on"][style*="readium-darken-on"] img { - -webkit-filter: brightness(80%); - filter: brightness(80%); -} - -/* Invert all images on user’s demand */ - -:root[style*="readium-night-on"][style*="readium-invert-on"] img { - -webkit-filter: invert(100%); - filter: invert(100%); -} - -/* Darken and invert on user’s demand */ - -:root[style*="readium-night-on"][style*="readium-darken-on"][style*="readium-invert-on"] img { - -webkit-filter: brightness(80%) invert(100%); - filter: brightness(80%) invert(100%); -} - -/* Readium CSS - Sepia mode - - A preset theme for sepia mode - - Repo: https://github.com/readium/readium-css */ - -/* CONFIG */ - -:root[style*="readium-sepia-on"] { - --RS__backgroundColor: #faf4e8; - --RS__textColor: #121212; - - --RS__linkColor: #0000EE; - --RS__visitedColor: #551A8B; - - /* This can be customized but initial will re-use default value of the browser */ - --RS__selectionBackgroundColor: #b4d8fe; - --RS__selectionTextColor: inherit; - - --RS__maxLineLength: 40.01rem; /* Forcing a reflow in Blink/Webkit so that blend mode can work */ -} - -/* we don’t need to redeclare bg-color and color for :root since we will inherit and update from day/default mode */ - -:root[style*="readium-sepia-on"] body { - /* Should be transparent but Chrome bug https://bugs.chromium.org/p/chromium/issues/detail?id=711955&q=mix-blend-mode&colspec=ID%20Pri%20M%20Stars%20ReleaseBlock%20Component%20Status%20Owner%20Summary%20OS%20Modified */ - - color: inherit; - background-color: var(--RS__backgroundColor); -} - -:root[style*="readium-sepia-on"] a:link, -:root[style*="readium-sepia-on"] a:link * { - color: var(--RS__linkColor); -} - -:root[style*="readium-sepia-on"] a:visited, -:root[style*="readium-sepia-on"] a:visited * { - color: var(--RS__visitedColor); -} - -:root[style*="readium-sepia-on"] svg, -:root[style*="readium-sepia-on"] img { - /* Make sure the proper bg-color is used for the blend mode */ - background-color: transparent !important; - mix-blend-mode: multiply; -} - -/* Readium CSS - OS Accessibility Modes - - A stylesheet to deal with OS accessibility settings - - Repo: https://github.com/readium/readium-css */ - -/* Windows high contrast colors are mapped to CSS system color keywords - See http://www.gwhitworth.com/blog/2017/04/how-to-use-ms-high-contrast */ - -@media screen and (-ms-high-contrast: active) { - :root { - color: windowText !important; - background-color: window !important; - } - - /* The following selectors are super funky but it makes sure everything is inherited, this is indeed critical for this mode */ - :root :not(#\#):not(#\#):not(#\#), - :root :not(#\#):not(#\#):not(#\#) :not(#\#):not(#\#):not(#\#) - :root :not(#\#):not(#\#):not(#\#) :not(#\#):not(#\#):not(#\#) :not(#\#):not(#\#):not(#\#) { - color: inherit !important; - background-color: inherit !important; - } - - .readiumCSS-mo-active-default { - color: highlightText !important; - background-color: highlight !important; - } - - /* For links, hyperlink keyword is automatically set */ - - /* Should we also set user highlights? */ -} - -@media screen and (-ms-high-contrast: white-on-black) { - :root[style*="readium-night-on"] img[class*="gaiji"], - :root[style*="readium-night-on"] *[epub\:type~="titlepage"] img:only-child { - -webkit-filter: none !important; - filter: none !important; - } - :root[style*="readium-night-on"][style*="readium-invert-on"] img { - -webkit-filter: none !important; - filter: none !important; - } - :root[style*="readium-night-on"][style*="readium-darken-on"][style*="readium-invert-on"] img { - -webkit-filter: brightness(80%); - filter: brightness(80%); - } -} - -/* Will be true on recent versions of iOS and MacOS if inverted setting enabled by the user */ - -@media screen and (inverted-colors) { - :root[style*="readium-night-on"] img[class*="gaiji"], - :root[style*="readium-night-on"] *[epub\:type~="titlepage"] img:only-child { - -webkit-filter: none !important; - filter: none !important; - } - :root[style*="readium-night-on"][style*="readium-invert-on"] img { - -webkit-filter: none !important; - filter: none !important; - } - :root[style*="readium-night-on"][style*="readium-darken-on"][style*="readium-invert-on"] img { - -webkit-filter: brightness(80%); - filter: brightness(80%); - } -} - -@media screen and (monochrome) { - /* Grayscale (Implemented in Safari, what about eInk?) */ - /* Must deal with anything color (contrast) so must be managed at the night/sepia/theme level :( */ -} - -@media screen and (prefers-reduced-motion) { - /* If reduced motion is set on MacOS, in case we have animation/transition */ -} - -/* Readium CSS - Columns number pref - - A submodule managing columns number for user settings - Part of “Chrome Advanced” class – no flag required. - - Repo: https://github.com/readium/readium-css */ - -/* Number of columns = 1 | 2 */ - -/* We still need to see if we allow users to force number of columns for all configs, currently it behaves as an "auto" setting */ - -/* apply col setting except for mobile portrait */ - -@media screen and (min-width: 60em), screen and (min-device-width: 36em) and (max-device-width: 47em) and (orientation: landscape) { - :root[style*="--USER__colCount: 1"], - :root[style*="--USER__colCount:1"], - :root[style*="--USER__colCount: 2"], - :root[style*="--USER__colCount:2"] { - -webkit-column-count: var(--USER__colCount); - -moz-column-count: var(--USER__colCount); - column-count: var(--USER__colCount); - } - - /* If one column, make sure we limit line-length */ - :root[style*="--USER__colCount: 1"], - :root[style*="--USER__colCount:1"] { - --RS__maxLineLength: 40rem !important; /* This is the only way for the user setting to work in webkit… */ - --RS__colWidth: 100vw; - } - - /* If smartphone landscape, and 2 columns, col width the same as iPad landscape + desktop */ - :root[style*="--USER__colCount: 2"], - :root[style*="--USER__colCount:2"] { - --RS__colWidth: auto; /* User explicitely tells he/she wants 2 columns, we reset floor value */ - } -} - -/* Readium CSS - Page margins pref - - A submodule managing page margins for user settings - Part of “Chrome Advanced” class – no flag required. - - Repo: https://github.com/readium/readium-css */ - -/* Page Margins: the user margin is a factor of the page gutter e.g. 0.5, 0.75, 1, 1.25, 1.5, etc. */ - -:root[style*="--USER__pageMargins"] body { - padding: 0 calc(var(--RS__pageGutter) * var(--USER__pageMargins)) !important; -} - -/* Readium CSS - Custom colors pref - - A submodule managing custom colors for user settings - Part of “Chrome Advanced” class – no flag required. - - Repo: https://github.com/readium/readium-css */ - -:root[style*="--USER__backgroundColor"] { - background-color: var(--USER__backgroundColor) !important; -} - -:root[style*="--USER__backgroundColor"] * { - background-color: transparent !important; -} - -:root[style*="--USER__textColor"] { - color: var(--USER__textColor) !important; -} - -:root[style*="--USER__textColor"] *:not(h1):not(h2):not(h3):not(h4):not(h5):not(h6):not(pre) { - color: inherit !important; -} - -/* Readium CSS - Text align pref - - A submodule managing text-align for user settings - Part of “User Overrides Advanced” class – “advanced settings” flag required. - - Repo: https://github.com/readium/readium-css */ - -:root[style*="readium-advanced-on"][style*="--USER__textAlign"] { - text-align: var(--USER__textAlign); -} - -:root[style*="readium-advanced-on"][style*="--USER__textAlign"] body, -:root[style*="readium-advanced-on"][style*="--USER__textAlign"] *:not(blockquote):not(figcaption) p, -:root[style*="readium-advanced-on"][style*="--USER__textAlign"] li { - text-align: inherit !important; - -moz-text-align-last: auto !important; - -epub-text-align-last: auto !important; - text-align-last: auto !important; -} - -/* In case something goes wrong at the programmatic level + rtl for body + rtl in ltr */ - -:root[style*="readium-advanced-on"][dir="rtl"][style*="--USER__textAlign: left"], -:root[style*="readium-advanced-on"][dir="rtl"][style*="--USER__textAlign:left"], -:root[style*="readium-advanced-on"][style*="--USER__textAlign: left"] *[dir="rtl"], -:root[style*="readium-advanced-on"][style*="--USER__textAlign:left"] *[dir="rtl"] { - text-align: right; -} - -/* Edge, if logical value is used, think of it as a polyfill. For LTR, it will fall back to the default, which is left */ - -:root[style*="readium-advanced-on"][dir="rtl"][style*="--USER__textAlign: start"], -:root[style*="readium-advanced-on"][dir="rtl"][style*="--USER__textAlign:start"] { - text-align: right; -} - -/* Readium CSS - Hyphenation pref - - A submodule managing hyphens for user settings - Part of “User Overrides Advanced” class – “advanced settings” flag required. - - Repo: https://github.com/readium/readium-css */ - -/* Managing hyphenation automatically for text-align values */ - -:root[style*="readium-advanced-on"][style*="--USER__textAlign: justify"] body, -:root[style*="readium-advanced-on"][style*="--USER__textAlign:justify"] body { - -webkit-hyphens: auto; - -moz-hyphens: auto; - -ms-hyphens: auto; - -epub-hyphens: auto; - hyphens: auto; -} - -:root[style*="readium-advanced-on"][style*="--USER__textAlign: left"] body, -:root[style*="readium-advanced-on"][style*="--USER__textAlign:left"] body, -:root[style*="readium-advanced-on"][style*="--USER__textAlign: right"] body, -:root[style*="readium-advanced-on"][style*="--USER__textAlign:right"] body { - -webkit-hyphens: none; - -moz-hyphens: none; - -ms-hyphens: none; - -epub-hyphens: none; - hyphens: none; -} - -/* Managing the user override */ - -:root[style*="readium-advanced-on"][style*="--USER__bodyHyphens"] { - -webkit-hyphens: var(--USER__bodyHyphens) !important; - -moz-hyphens: var(--USER__bodyHyphens) !important; - -ms-hyphens: var(--USER__bodyHyphens) !important; - -epub-hyphens: var(--USER__bodyHyphens) !important; - hyphens: var(--USER__bodyHyphens) !important; -} - -/* Sorry, we can’t use `:matches`, `:-moz-any` or `:-webkit-any` because MS doesn’t support it yet */ - -:root[style*="readium-advanced-on"][style*="--USER__bodyHyphens"] body, -:root[style*="readium-advanced-on"][style*="--USER__bodyHyphens"] p, -:root[style*="readium-advanced-on"][style*="--USER__bodyHyphens"] li, -:root[style*="readium-advanced-on"][style*="--USER__bodyHyphens"] div, -:root[style*="readium-advanced-on"][style*="--USER__bodyHyphens"] dd { - -webkit-hyphens: inherit; - -moz-hyphens: inherit; - -ms-hyphens: inherit; - -epub-hyphens: inherit; - hyphens: inherit; -} - -/* Readium CSS - Font Family pref - - A submodule managing font-family for user settings - Part of “User Overrides” class – “font override” flag required. - - Repo: https://github.com/readium/readium-css */ - -:root[style*="readium-font-on"][style*="--USER__fontFamily"] { - font-family: var(--USER__fontFamily) !important; -} - -:root[style*="readium-font-on"][style*="--USER__fontFamily"] body, -:root[style*="readium-font-on"][style*="--USER__fontFamily"] p, -:root[style*="readium-font-on"][style*="--USER__fontFamily"] li, -:root[style*="readium-font-on"][style*="--USER__fontFamily"] div, -:root[style*="readium-font-on"][style*="--USER__fontFamily"] dt, -:root[style*="readium-font-on"][style*="--USER__fontFamily"] dd { - font-family: inherit !important; -} - -:root[style*="readium-font-on"][style*="--USER__fontFamily"] i:not([lang]), -:root[style*="readium-font-on"][style*="--USER__fontFamily"] i:not([xml\:lang]), -:root[style*="readium-font-on"][style*="--USER__fontFamily"] em:not([lang]), -:root[style*="readium-font-on"][style*="--USER__fontFamily"] em:not([xml\:lang]), -:root[style*="readium-font-on"][style*="--USER__fontFamily"] cite:not([lang]), -:root[style*="readium-font-on"][style*="--USER__fontFamily"] cite:not([xml\:lang]), -:root[style*="readium-font-on"][style*="--USER__fontFamily"] b:not([lang]), -:root[style*="readium-font-on"][style*="--USER__fontFamily"] b:not([xml\:lang]), -:root[style*="readium-font-on"][style*="--USER__fontFamily"] strong:not([lang]), -:root[style*="readium-font-on"][style*="--USER__fontFamily"] strong:not([xml\:lang]), -:root[style*="readium-font-on"][style*="--USER__fontFamily"] span:not([lang]), -:root[style*="readium-font-on"][style*="--USER__fontFamily"] span:not([xml\:lang]) { - font-family: inherit !important; -} - -/* Readium CSS - A11y font pref - - A submodule managing a11y text normalization for user settings - Part of “User Overrides” class – “font override” flag required. - - Repo: https://github.com/readium/readium-css */ - -/* For AccessibleDfA, we need to normalize font-weight and font-style since only the normal style is available */ - -:root[style*="readium-font-on"][style*="AccessibleDfA"] { - /* We won’t use the variable there since we need fallbacks for missing characters */ - font-family: AccessibleDfA, Verdana, Tahoma, "Trebuchet MS", sans-serif !important; - --RS__lineHeightCompensation: 1.167; -} - -:root[style*="readium-font-on"][style*="IA Writer Duospace"] { - /* We won’t use the variable there since we need fallbacks for missing characters */ - font-family: "IA Writer Duospace", Menlo, "DejaVu Sans Mono", "Bitstream Vera Sans Mono", Courier, monospace !important; - --RS__lineHeightCompensation: 1.167; -} - -:root[style*="readium-font-on"][style*="readium-a11y-on"] { - font-family: var(--USER__fontFamily) !important; - --RS__lineHeightCompensation: 1.167; -} - -/* Maybe users want a setting to normalize any font offered so there is a “a11y Normalize” flag for it */ - -:root[style*="readium-font-on"][style*="AccessibleDfA"], -:root[style*="readium-font-on"][style*="IA Writer Duospace"], -:root[style*="readium-font-on"][style*="readium-a11y-on"] { - font-style: normal !important; - font-weight: normal !important; -} - -/* Targeting everything except code. Note that Open Dyslexic has a monospaced font for code */ - -:root[style*="readium-font-on"][style*="AccessibleDfA"] *:not(code):not(var):not(kbd):not(samp), -:root[style*="readium-font-on"][style*="IA Writer Duospace"] *:not(code):not(var):not(kbd):not(samp), -:root[style*="readium-font-on"][style*="readium-a11y-on"] *:not(code):not(var):not(kbd):not(samp) { - font-family: inherit !important; - font-style: inherit !important; - font-weight: inherit !important; -} - -/* Normalizing text-decoration, subs and sups */ - -:root[style*="readium-font-on"][style*="AccessibleDfA"] *, -:root[style*="readium-font-on"][style*="IA Writer Duospace"] *, -:root[style*="readium-font-on"][style*="readium-a11y-on"] * { - text-decoration: none !important; - font-variant-caps: normal !important; - font-variant-numeric: normal !important; - font-variant-position: normal !important; -} - -:root[style*="readium-font-on"][style*="AccessibleDfA"] sup, -:root[style*="readium-font-on"][style*="IA Writer Duospace"] sup, -:root[style*="readium-font-on"][style*="readium-a11y-on"] sup, -:root[style*="readium-font-on"][style*="AccessibleDfA"] sub, -:root[style*="readium-font-on"][style*="IA Writer Duospace"] sub, -:root[style*="readium-font-on"][style*="readium-a11y-on"] sub { - font-size: 1rem !important; - vertical-align: baseline !important; -} - -/* Readium CSS - Font size pref - - A submodule managing font-size for user settings - Part of “User Overrides” class – no flag required. - - Repo: https://github.com/readium/readium-css */ - -:root[style*="--USER__fontSize"] { - font-size: var(--USER__fontSize) !important; -} - -/* Readium CSS - Line height pref - - A submodule managing line-height for user settings - Part of “User Overrides Advanced” class – “advanced settings” flag required. - - Repo: https://github.com/readium/readium-css */ - -:root[style*="readium-advanced-on"][style*="--USER__lineHeight"] { - line-height: var(--USER__lineHeight) !important; -} - -:root[style*="readium-advanced-on"][style*="--USER__lineHeight"] body, -:root[style*="readium-advanced-on"][style*="--USER__lineHeight"] p, -:root[style*="readium-advanced-on"][style*="--USER__lineHeight"] li, -:root[style*="readium-advanced-on"][style*="--USER__lineHeight"] div { - line-height: inherit; -} - -/* Readium CSS - Para spacing pref - - A submodule managing paragraphs’ top and bottom margins for user settings - Part of “User Overrides Advanced” class – “advanced settings” flag required. - - Repo: https://github.com/readium/readium-css */ - -:root[style*="readium-advanced-on"][style*="--USER__paraSpacing"] p { - margin-top: var(--USER__paraSpacing) !important; - margin-bottom: var(--USER__paraSpacing) !important; -} - -/* Readium CSS - Para indent pref - - A submodule managing paragraphs’ text-indent for user settings - Part of “User Overrides Advanced” class – “advanced settings” flag required. - - Repo: https://github.com/readium/readium-css */ - -:root[style*="readium-advanced-on"][style*="--USER__paraIndent"] p { - text-indent: var(--USER__paraIndent) !important; -} - -/* If there are inline-block elements in paragraphs, text-indent will inherit so we must reset it */ - -:root[style*="readium-advanced-on"][style*="--USER__paraIndent"] p *, -:root[style*="readium-advanced-on"][style*="--USER__paraIndent"] p:first-letter { - text-indent: 0 !important; -} - -/* Readium CSS - Word spacing pref - - A submodule managing word-spacing for user settings - Part of “User Overrides Advanced” class – “advanced settings” flag required. - - Repo: https://github.com/readium/readium-css */ - -:root[style*="readium-advanced-on"][style*="--USER__wordSpacing"] h1, -:root[style*="readium-advanced-on"][style*="--USER__wordSpacing"] h2, -:root[style*="readium-advanced-on"][style*="--USER__wordSpacing"] h3, -:root[style*="readium-advanced-on"][style*="--USER__wordSpacing"] h4, -:root[style*="readium-advanced-on"][style*="--USER__wordSpacing"] h5, -:root[style*="readium-advanced-on"][style*="--USER__wordSpacing"] h6, -:root[style*="readium-advanced-on"][style*="--USER__wordSpacing"] p, -:root[style*="readium-advanced-on"][style*="--USER__wordSpacing"] li, -:root[style*="readium-advanced-on"][style*="--USER__wordSpacing"] div { - word-spacing: var(--USER__wordSpacing); -} - -/* Readium CSS - Letter spacing pref - - A submodule managing letter-spacing for user settings - Part of “User Overrides Advanced” class – “advanced settings” flag required. - - Repo: https://github.com/readium/readium-css */ - -:root[style*="readium-advanced-on"][style*="--USER__letterSpacing"] h1, -:root[style*="readium-advanced-on"][style*="--USER__letterSpacing"] h2, -:root[style*="readium-advanced-on"][style*="--USER__letterSpacing"] h3, -:root[style*="readium-advanced-on"][style*="--USER__letterSpacing"] h4, -:root[style*="readium-advanced-on"][style*="--USER__letterSpacing"] h5, -:root[style*="readium-advanced-on"][style*="--USER__letterSpacing"] h6, -:root[style*="readium-advanced-on"][style*="--USER__letterSpacing"] p, -:root[style*="readium-advanced-on"][style*="--USER__letterSpacing"] li, -:root[style*="readium-advanced-on"][style*="--USER__letterSpacing"] div { - letter-spacing: var(--USER__letterSpacing); - font-variant: none; -} - -/* Readium CSS - Font size normalize - - A stylesheet to normalize font-size - - Repo: https://github.com/readium/readium-css */ - -/* STYLES */ - -/* :root is used so that you can quickly add a class or attribute if you prefer e.g. `:root[data-rs-normalize]` */ - -/* We create a default so that you don’t need to explicitly set one in the DOM. - Once the “Publisher’s styles” checkbox is unchecked, the normalize is applied automatically */ - -:root[style*="readium-advanced-on"] { - --USER__typeScale: 1.2; /* This is the default type scale you’ll find in most publications */ -} - -:root[style*="readium-advanced-on"] p, -:root[style*="readium-advanced-on"] li, -:root[style*="readium-advanced-on"] div, -:root[style*="readium-advanced-on"] pre, -:root[style*="readium-advanced-on"] dd { - font-size: 1rem !important; -} - -:root[style*="readium-advanced-on"] h1 { - /* Fallback if browser doesn’t support vars */ - font-size: 1.75rem !important; - font-size: calc(((1rem * var(--USER__typeScale)) * var(--USER__typeScale)) * var(--USER__typeScale)) !important; -} - -:root[style*="readium-advanced-on"] h2 { - /* Fallback if browser doesn’t support vars */ - font-size: 1.5rem !important; - font-size: calc((1rem * var(--USER__typeScale)) * var(--USER__typeScale)) !important; -} - -:root[style*="readium-advanced-on"] h3 { - /* Fallback if browser doesn’t support vars */ - font-size: 1.25rem !important; - font-size: calc(1rem * var(--USER__typeScale)) !important; -} - -:root[style*="readium-advanced-on"] h4, -:root[style*="readium-advanced-on"] h5, -:root[style*="readium-advanced-on"] h6 { - font-size: 1rem !important; -} - -:root[style*="readium-advanced-on"] small { - font-size: smaller !important; -} - -:root[style*="readium-advanced-on"] sub, -:root[style*="readium-advanced-on"] sup { - font-size: 67.5% !important; -} - -/* The following styles kick in if you define the typeScale variable in the DOM. - No need to repeat declarations which don’t make use of the variable */ - -:root[style*="readium-advanced-on"][style*="--USER__typeScale"] h1 { - font-size: calc(((1rem * var(--USER__typeScale)) * var(--USER__typeScale)) * var(--USER__typeScale)) !important; -} - -:root[style*="readium-advanced-on"][style*="--USER__typeScale"] h2 { - font-size: calc((1rem * var(--USER__typeScale)) * var(--USER__typeScale)) !important; -} - -:root[style*="readium-advanced-on"][style*="--USER__typeScale"] h3 { - font-size: calc(1rem * var(--USER__typeScale)) !important; -} -/*# sourceMappingURL=ReadiumCSS-after.css.map */ \ No newline at end of file diff --git a/css/demo/css/ReadiumCSS-before.css b/css/demo/css/ReadiumCSS-before.css deleted file mode 100644 index a56caa26..00000000 --- a/css/demo/css/ReadiumCSS-before.css +++ /dev/null @@ -1,433 +0,0 @@ -/* - * Readium CSS (v. 1.1.0) - * Developers: Jiminy Panoz - * Copyright (c) 2017. Readium Foundation. All rights reserved. - * Use of this source code is governed by a BSD-style license which is detailed in the - * LICENSE file present in the project repository where this source code is maintained. -*/ - -@namespace url("http://www.w3.org/1999/xhtml"); - -@namespace epub url("http://www.idpf.org/2007/ops"); - -@namespace m url("http://www.w3.org/1998/Math/MathML/"); - -@namespace svg url("http://www.w3.org/2000/svg"); - -@-ms-viewport{ - width:device-width; -} - -@viewport{ - width:device-width; - zoom:1; -} - -:root{ - --RS__oldStyleTf:"Iowan Old Style", "Sitka Text", palatino, "Book Antiqua", serif; - --RS__modernTf:athelas, constantia, georgia, serif; - --RS__sansTf:-apple-system, system-ui, blinkmacsystemfont, "Segoe UI", roboto, "Helvetica Neue", arial, sans-serif; - --RS__humanistTf:seravek, calibri, roboto, arial, sans-serif; - --RS__monospaceTf:"Andale Mono", consolas, monospace; - --RS__baseFontFamily:var(--RS__oldStyleTf); - --RS__lineHeightCompensation:1; - --RS__baseLineHeight:calc((1em + (2ex - 1ch) - ((1rem - 16px) * 0.1667)) * var(--RS__lineHeightCompensation)); -} - -html{ - font-family:var(--RS__baseFontFamily); - line-height:1.6; - line-height:var(--RS__baseLineHeight); - text-rendering:optimizelegibility; -} - -h1, h2, h3{ - line-height:normal; -} - -:lang(ja), -:lang(zh), -:lang(ko){ - word-wrap:break-word; - -webkit-line-break:strict; - -epub-line-break:strict; - line-break:strict; -} - -math{ - font-family:"Latin Modern Math", "STIX Two Math", "XITS Math", "STIX Math", "Libertinus Math", "TeX Gyre Termes Math", "TeX Gyre Bonum Math", "TeX Gyre Schola", "DejaVu Math TeX Gyre", "TeX Gyre Pagella Math", "Asana Math", "Cambria Math", "Lucida Bright Math", "Minion Math", STIXGeneral, STIXSizeOneSym, Symbol, "Times New Roman", serif; -} - -:lang(am){ - --RS__baseFontFamily:kefa, nyala, roboto, noto, "Noto Sans Ethiopic", serif; - --RS__lineHeightCompensation:1.167; -} - -:lang(ar){ - --RS__baseFontFamily:"Geeza Pro", "Arabic Typesetting", roboto, noto, "Noto Naskh Arabic", "Times New Roman", serif; -} - -:lang(bn){ - --RS__baseFontFamily:"Kohinoor Bangla", "Bangla Sangam MN", vrinda, roboto, noto, "Noto Sans Bengali", sans-serif; - --RS__lineHeightCompensation:1.067; -} - -:lang(bo){ - --RS__baseFontFamily:kailasa, "Microsoft Himalaya", roboto, noto, "Noto Sans Tibetan", sans-serif; -} - -:lang(chr){ - --RS__baseFontFamily:"Plantagenet Cherokee", roboto, noto, "Noto Sans Cherokee"; - --RS__lineHeightCompensation:1.167; -} - -:lang(fa){ - --RS__baseFontFamily:"Geeza Pro", "Arabic Typesetting", roboto, noto, "Noto Naskh Arabic", "Times New Roman", serif; -} - -:lang(gu){ - --RS__baseFontFamily:"Gujarati Sangam MN", "Nirmala UI", shruti, roboto, noto, "Noto Sans Gujarati", sans-serif; - --RS__lineHeightCompensation:1.167; -} - -:lang(he){ - --RS__baseFontFamily:"New Peninim MT", "Arial Hebrew", gisha, "Times New Roman", roboto, noto, "Noto Sans Hebrew" sans-serif; - --RS__lineHeightCompensation:1.1; -} - -:lang(hi){ - --RS__baseFontFamily:"Kohinoor Devanagari", "Devanagari Sangam MN", kokila, "Nirmala UI", roboto, noto, "Noto Sans Devanagari", sans-serif; - - --RS__lineHeightCompensation:1.1; -} - -:lang(hy){ - --RS__baseFontFamily:mshtakan, sylfaen, roboto, noto, "Noto Serif Armenian", serif; -} - -:lang(iu){ - --RS__baseFontFamily:"Euphemia UCAS", euphemia, roboto, noto, "Noto Sans Canadian Aboriginal", sans-serif; -} - -:lang(ja){ - --RS__baseFontFamily:yugothic, "Hiragino Maru Gothic ProN", "Hiragino Sans", "Yu Gothic UI", "Meiryo UI", "MS Gothic", roboto, noto, "Noto Sans CJK JP", sans-serif; - --RS__lineHeightCompensation:1.167; - --RS__serif-ja:"Hiragino Mincho ProN", "Hiragino Mincho Pro", "YuMincho", "BIZ UDPMincho", "Yu Mincho", "MS P明朝", "MS PMincho", serif; - --RS__sans-serif-ja:"Hiragino Sans", "Hiragino Kaku Gothic ProN", "Hiragino Kaku Gothic Pro", "ヒラギノ角ゴ W3", "YuGothic", "Yu Gothic Medium", "BIZ UDPGothic", "Yu Gothic", "MS Pゴシック", "MS PGothic", sans-serif; - --RS__serif-ja-v:"Hiragino Mincho ProN", "Hiragino Mincho Pro", "YuMincho", "BIZ UDMincho", "Yu Mincho", "MS明朝", "MS Mincho", serif; - --RS__sans-serif-ja-v:"Hiragino Sans", "Hiragino Kaku Gothic ProN", "Hiragino Kaku Gothic Pro", "ヒラギノ角ゴ W3", "YuGothic", "Yu Gothic Medium", "BIZ UDGothic", "Yu Gothic", "MSゴシック", "MS Gothic", sans-serif; -} - -:lang(km){ - --RS__baseFontFamily:"Khmer Sangam MN", "Leelawadee UI", "Khmer UI", roboto, noto, "Noto Sans Khmer", sans-serif; - --RS__lineHeightCompensation:1.067; -} - -:lang(kn){ - --RS__baseFontFamily:"Kannada Sangam MN", "Nirmala UI", tunga, roboto, noto, "Noto Sans Kannada", sans-serif; - --RS__lineHeightCompensation:1.1; -} - -:lang(ko){ - --RS__baseFontFamily:"Nanum Gothic", "Apple SD Gothic Neo", "Malgun Gothic", roboto, noto, "Noto Sans CJK KR", sans-serif; - --RS__lineHeightCompensation:1.167; -} - -:lang(lo){ - --RS__baseFontFamily:"Lao Sangam MN", "Leelawadee UI", "Lao UI", roboto, noto, "Noto Sans Lao", sans-serif; -} - -:lang(ml){ - --RS__baseFontFamily:"Malayalam Sangam MN", "Nirmala UI", kartika, roboto, noto, "Noto Sans Malayalam", sans-serif; - --RS__lineHeightCompensation:1.067; -} - -:lang(or){ - --RS__baseFontFamily:"Oriya Sangam MN", "Nirmala UI", kalinga, roboto, noto, "Noto Sans Oriya", sans-serif; - --RS__lineHeightCompensation:1.167; -} - -:lang(pa){ - --RS__baseFontFamily:"Gurmukhi MN", "Nirmala UI", kartika, roboto, noto, "Noto Sans Gurmukhi", sans-serif; - --RS__lineHeightCompensation:1.1; -} - -:lang(si){ - --RS__baseFontFamily:"Sinhala Sangam MN", "Nirmala UI", "Iskoola Pota", roboto, noto, "Noto Sans Sinhala", sans-serif; - --RS__lineHeightCompensation:1.167; -} - -:lang(ta){ - --RS__baseFontFamily:"Tamil Sangam MN", "Nirmala UI", latha, roboto, noto, "Noto Sans Tamil", sans-serif; - --RS__lineHeightCompensation:1.067; -} - -:lang(te){ - --RS__baseFontFamily:"Kohinoor Telugu", "Telugu Sangam MN", "Nirmala UI", gautami, roboto, noto, "Noto Sans Telugu", sans-serif; -} - -:lang(th){ - --RS__baseFontFamily:"Thonburi", "Leelawadee UI", "Cordia New", roboto, noto, "Noto Sans Thai", sans-serif; - --RS__lineHeightCompensation:1.067; -} - -:lang(zh){ - --RS__baseFontFamily:"方体", "PingFang SC", "黑体", "Heiti SC", "Microsoft JhengHei UI", "Microsoft JhengHei", roboto, noto, "Noto Sans CJK SC", sans-serif; - --RS__lineHeightCompensation:1.167; -} - -:lang(zh-Hant), -:lang(zh-TW){ - --RS__baseFontFamily:"方體", "PingFang TC", "黑體", "Heiti TC", "Microsoft JhengHei UI", "Microsoft JhengHei", roboto, noto, "Noto Sans CJK TC", sans-serif; - --RS__lineHeightCompensation:1.167; -} - -:lang(zh-HK){ - --RS__baseFontFamily:"方體", "PingFang HK", "方體", "PingFang TC", "黑體", "Heiti TC", "Microsoft JhengHei UI", "Microsoft JhengHei", roboto, noto, "Noto Sans CJK TC", sans-serif; - --RS__lineHeightCompensation:1.167; -} - -:root{ - --RS__backgroundColor:#FFFFFF; - --RS__textColor:#121212; - --RS__selectionBackgroundColor:#b4d8fe; - --RS__selectionTextColor:inherit; -} - -:root{ - color:var(--RS__textColor) !important; - background-color:var(--RS__backgroundColor) !important; -} - -::-moz-selection{ - color:var(--RS__selectionTextColor); - background-color:var(--RS__selectionBackgroundColor); -} - -::selection{ - color:var(--RS__selectionTextColor); - background-color:var(--RS__selectionBackgroundColor); -} - -@font-face{ - font-family:AccessibleDfA; - font-style:normal; - font-weight:normal; - src:local("AccessibleDfA"), url("fonts/AccessibleDfA-Regular.woff2") format("woff2"), url("fonts/AccessibleDfA-Regular.woff") format("woff"); -} - -@font-face{ - font-family:AccessibleDfA; - font-style:normal; - font-weight:bold; - src:local("AccessibleDfA"), url("fonts/AccessibleDfA-Bold.woff2") format("woff2"); -} - -@font-face{ - font-family:AccessibleDfA; - font-style:italic; - font-weight:normal; - src:local("AccessibleDfA"), url("fonts/AccessibleDfA-Italic.woff2") format("woff2"); -} - -@font-face{ - font-family:"IA Writer Duospace"; - font-style:normal; - font-weight:normal; - src:local("iAWriterDuospace-Regular"), url("fonts/iAWriterDuospace-Regular.ttf") format("truetype"); -} - -body{ - widows:2; - orphans:2; -} - -figcaption, th, td{ - widows:1; - orphans:1; -} - -h2, h3, h4, h5, h6, dt, -hr, caption{ - -webkit-column-break-after:avoid; - page-break-after:avoid; - break-after:avoid; -} - -h1, h2, h3, h4, h5, h6, dt, -figure, tr{ - -webkit-column-break-inside:avoid; - page-break-inside:avoid; - break-inside:avoid; -} - -body{ - -webkit-hyphenate-character:"\002D"; - -moz-hyphenate-character:"\002D"; - -ms-hyphenate-character:"\002D"; - hyphenate-character:"\002D"; - -webkit-hyphenate-limit-lines:3; - -ms-hyphenate-limit-lines:3; - hyphenate-limit-lines:3; -} - -h1, h2, h3, h4, h5, h6, dt, -figcaption, pre, caption, address, -center, code, var{ - -ms-hyphens:none; - -moz-hyphens:none; - -webkit-hyphens:none; - -epub-hyphens:none; - hyphens:none; -} - -body{ - font-variant-numeric:oldstyle-nums proportional-nums; -} - -:lang(ja) body, -:lang(zh) body, -:lang(ko) body{ - font-variant-numeric:lining-nums proportional-nums; -} - -h1, h2, h3, h4, h5, h6, dt{ - font-variant-numeric:lining-nums proportional-nums; -} - -table{ - font-variant-numeric:lining-nums tabular-nums; -} - -code, var{ - font-variant-ligatures:none; - font-variant-numeric:lining-nums tabular-nums slashed-zero; -} - -rt{ - font-variant-east-asian:ruby; -} - -:lang(ar){ - font-variant-ligatures:common-ligatures; -} - -:lang(ko){ - font-kerning:normal; -} - -hr{ - color:inherit; - border-color:currentcolor; -} - -table, th, td{ - border-color:currentcolor; -} - -figure, blockquote{ - margin:1em 5%; -} - -ul, ol{ - padding-left:5%; -} - -dd{ - margin-left:5%; -} - -pre{ - white-space:pre-wrap; - -ms-tab-size:2; - -moz-tab-size:2; - -webkit-tab-size:2; - tab-size:2; -} - -abbr[title], acronym[title]{ - text-decoration:dotted underline; -} - -nobr wbr{ - white-space:normal; -} - -ruby > rt, ruby > rp{ - -webkit-user-select:none; - -moz-user-select:none; - -ms-user-select:none; - user-select:none; -} - -*:lang(ja):not([lang="ja-Latn"]):not([xml\:lang="ja-Latn"]):not([lang="ja-Cyrl"]):not([xml\:lang="ja-Cyrl"]), -*:lang(zh):not([lang="zh-Latn"]):not([xml\:lang="zh-Latn"]):not([lang="zh-Cyrl"]):not([xml\:lang="zh-Cyrl"]), -*:lang(ko):not([lang="ko-Latn"]):not([xml\:lang="ko-Latn"]):not([lang="ko-Cyrl"]):not([xml\:lang="ko-Cyrl"]), -:lang(ja):not([lang="ja-Latn"]):not([xml\:lang="ja-Latn"]):not([lang="ja-Cyrl"]):not([xml\:lang="ja-Cyrl"]) cite, -:lang(ja):not([lang="ja-Latn"]):not([xml\:lang="ja-Latn"]):not([lang="ja-Cyrl"]):not([xml\:lang="ja-Cyrl"]) dfn, -:lang(ja):not([lang="ja-Latn"]):not([xml\:lang="ja-Latn"]):not([lang="ja-Cyrl"]):not([xml\:lang="ja-Cyrl"]) em, -:lang(ja):not([lang="ja-Latn"]):not([xml\:lang="ja-Latn"]):not([lang="ja-Cyrl"]):not([xml\:lang="ja-Cyrl"]) i, -:lang(zh):not([lang="zh-Latn"]):not([xml\:lang="zh-Latn"]):not([lang="zh-Cyrl"]):not([xml\:lang="zh-Cyrl"]) cite, -:lang(zh):not([lang="zh-Latn"]):not([xml\:lang="zh-Latn"]):not([lang="zh-Cyrl"]):not([xml\:lang="zh-Cyrl"]) dfn, -:lang(zh):not([lang="zh-Latn"]):not([xml\:lang="zh-Latn"]):not([lang="zh-Cyrl"]):not([xml\:lang="zh-Cyrl"]) em, -:lang(zh):not([lang="zh-Latn"]):not([xml\:lang="zh-Latn"]):not([lang="zh-Cyrl"]):not([xml\:lang="zh-Cyrl"]) i, -:lang(ko):not([lang="ko-Latn"]):not([xml\:lang="ko-Latn"]):not([lang="ko-Cyrl"]):not([xml\:lang="ko-Cyrl"]) cite, -:lang(ko):not([lang="ko-Latn"]):not([xml\:lang="ko-Latn"]):not([lang="ko-Cyrl"]):not([xml\:lang="ko-Cyrl"]) dfn, -:lang(ko):not([lang="ko-Latn"]):not([xml\:lang="ko-Latn"]):not([lang="ko-Cyrl"]):not([xml\:lang="ko-Cyrl"]) em, -:lang(ko):not([lang="ko-Latn"]):not([xml\:lang="ko-Latn"]):not([lang="ko-Cyrl"]):not([xml\:lang="ko-Cyrl"]) i{ - font-style:normal; -} - -:lang(ja) a, -:lang(zh) a, -:lang(ko) a{ - text-decoration:none; -} - -:root{ - --RS__maxMediaWidth:100%; - --RS__maxMediaHeight:95vh; - --RS__boxSizingMedia:border-box; - --RS__boxSizingTable:border-box; -} - -html{ - -webkit-line-box-contain:block glyphs replaced; -} - -:lang(ja){ - -webkit-line-box-contain:block inline replaced; -} - -a, h1, h2, h3, h4, h5, h6{ - word-wrap:break-word; -} - -div{ - max-width:var(--RS__maxMediaWidth); -} - -img, svg, video{ - object-fit:contain; - - width:auto; - height:auto; - max-width:var(--RS__maxMediaWidth); - max-height:var(--RS__maxMediaHeight) !important; - box-sizing:var(--RS__boxSizingMedia); - -webkit-column-break-inside:avoid; - page-break-inside:avoid; - break-inside:avoid; -} - -audio{ - max-width:100%; - -webkit-column-break-inside:avoid; - page-break-inside:avoid; - break-inside:avoid; - } - -table{ - max-width:var(--RS__maxMediaWidth); - box-sizing:var(--RS__boxSizingTable); -} \ No newline at end of file diff --git a/css/demo/css/ReadiumCSS-default.css b/css/demo/css/ReadiumCSS-default.css deleted file mode 100644 index 615a0d17..00000000 --- a/css/demo/css/ReadiumCSS-default.css +++ /dev/null @@ -1,163 +0,0 @@ -/* Readium CSS - Default module - - A stylesheet for unstyled ebooks based on HTML5 Suggested Rendering - Note: works in combination with Base module - - Repo: https://github.com/readium/readium-css */ - -/* CONFIG */ - -:root { - --RS__compFontFamily: var(--RS__baseFontFamily); - --RS__codeFontFamily: var(--RS__monospaceTf); - - --RS__typeScale: 1.125; /* 1.067 | 1.125 | 1.2 | 1.25 | 1.333 | 1.414 | 1.5 | 1.618 */ - --RS__baseFontSize: 100%; - - --RS__flowSpacing: 1.5rem; - --RS__paraSpacing: 0; - --RS__paraIndent: 1em; - - --RS__linkColor: #0000EE; - --RS__visitedColor: #551A8B; - - --RS__primaryColor: ; - --RS__secondaryColor: ; -} - -/* STYLES */ - -/* Typo */ - -body { - font-size: var(--RS__baseFontSize); -} - -h1, h2, h3, h4, h5, h6 { - font-family: var(--RS__compFontFamily); -} - -/* Flow content */ - -blockquote, figure, p, pre, -aside, footer, form, hr { - margin-top: var(--RS__flowSpacing); - margin-bottom: var(--RS__flowSpacing); -} - -p { - margin-top: var(--RS__paraSpacing); - margin-bottom: var(--RS__paraSpacing); - text-indent: var(--RS__paraIndent); -} - -h1 + p, h2 + p, h3 + p, h4 + p, h5 + p, h6 + p, -hr + p { - text-indent: 0; -} - -pre { - font-family: var(--RS__codeFontFamily); -} - -/* Phrasing content */ - -code, kbd, samp, tt { - font-family: var(--RS__codeFontFamily); -} - -sub, sup { - position: relative; - font-size: 67.5%; - line-height: 1; -} - -sub { - bottom: -0.2ex; -} - -sup { - bottom: 0; -} - -:link { - color: var(--RS__linkColor); -} - -:visited { - color: var(--RS__visitedColor); -} - -/* Headings */ - -h1 { - margin-top: calc(var(--RS__flowSpacing) * 2); - margin-bottom: calc(var(--RS__flowSpacing) * 2); - /* The following is base font size * typescale power of 3 */ - font-size: calc(((1em * var(--RS__typeScale)) * var(--RS__typeScale)) * var(--RS__typeScale)); -} - -h2 { - margin-top: calc(var(--RS__flowSpacing) * 2); - margin-bottom: var(--RS__flowSpacing); - /* The following is base font size * typescale power of 2 */ - font-size: calc((1em * var(--RS__typeScale)) * var(--RS__typeScale)); -} - -h3 { - margin-top: var(--RS__flowSpacing); - margin-bottom: var(--RS__flowSpacing); - font-size: calc(1em * var(--RS__typeScale)); -} - -h4 { - margin-top: var(--RS__flowSpacing); - margin-bottom: var(--RS__flowSpacing); - font-size: 1em; -} - -h5 { - margin-top: var(--RS__flowSpacing); - margin-bottom: var(--RS__flowSpacing); - font-size: 1em; - font-variant: small-caps; -} - -h6 { - margin-top: var(--RS__flowSpacing); - margin-bottom: 0; - font-size: 1em; - text-transform: lowercase; - font-variant: small-caps; -} - -/* Lists */ - -dl, ol, ul { - margin-top: var(--RS__flowSpacing); - margin-bottom: var(--RS__flowSpacing); -} - -/* Table */ - -table { - margin: var(--RS__flowSpacing) 0; - border: 1px solid currentColor; - border-collapse: collapse; - empty-cells: show; -} - -thead, tbody, tfoot, table > tr { - vertical-align: top; -} - -th { - text-align: left; -} - -th, td { - padding: 4px; - border: 1px solid currentColor; -} -/*# sourceMappingURL=ReadiumCSS-default.css.map */ \ No newline at end of file diff --git a/css/demo/css/fonts/AccessibleDfA.otf b/css/demo/css/fonts/AccessibleDfA.otf deleted file mode 100755 index 69c02218..00000000 Binary files a/css/demo/css/fonts/AccessibleDfA.otf and /dev/null differ diff --git a/css/demo/css/fonts/LICENSE-IaWriterDuospace.md b/css/demo/css/fonts/LICENSE-IaWriterDuospace.md deleted file mode 100755 index 3261f95c..00000000 --- a/css/demo/css/fonts/LICENSE-IaWriterDuospace.md +++ /dev/null @@ -1,110 +0,0 @@ -# IBM Plex Typeface - -Copyright © 2017 IBM Corp. with Reserved Font Name "Plex" - -This Font Software is licensed under the SIL Open Font License, Version 1.1. -This license is copied below, and is also available with a FAQ at: -http://scripts.sil.org/OFL - ------------------------------------------------------------ -SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 ------------------------------------------------------------ - -PREAMBLE -The goals of the Open Font License (OFL) are to stimulate worldwide -development of collaborative font projects, to support the font creation -efforts of academic and linguistic communities, and to provide a free and -open framework in which fonts may be shared and improved in partnership -with others. - -The OFL allows the licensed fonts to be used, studied, modified and -redistributed freely as long as they are not sold by themselves. The -fonts, including any derivative works, can be bundled, embedded, -redistributed and/or sold with any software provided that any reserved -names are not used by derivative works. The fonts and derivatives, -however, cannot be released under any other type of license. The -requirement for fonts to remain under this license does not apply -to any document created using the fonts or their derivatives. - -DEFINITIONS -"Font Software" refers to the set of files released by the Copyright -Holder(s) under this license and clearly marked as such. This may -include source files, build scripts and documentation. - -"Reserved Font Name" refers to any names specified as such after the -copyright statement(s). - -"Original Version" refers to the collection of Font Software components as -distributed by the Copyright Holder(s). - -"Modified Version" refers to any derivative made by adding to, deleting, -or substituting -- in part or in whole -- any of the components of the -Original Version, by changing formats or by porting the Font Software to a -new environment. - -"Author" refers to any designer, engineer, programmer, technical -writer or other person who contributed to the Font Software. - -PERMISSION & CONDITIONS -Permission is hereby granted, free of charge, to any person obtaining -a copy of the Font Software, to use, study, copy, merge, embed, modify, -redistribute, and sell modified and unmodified copies of the Font -Software, subject to the following conditions: - -1) Neither the Font Software nor any of its individual components, -in Original or Modified Versions, may be sold by itself. - -2) Original or Modified Versions of the Font Software may be bundled, -redistributed and/or sold with any software, provided that each copy -contains the above copyright notice and this license. These can be -included either as stand-alone text files, human-readable headers or -in the appropriate machine-readable metadata fields within text or -binary files as long as those fields can be easily viewed by the user. - -3) No Modified Version of the Font Software may use the Reserved Font -Name(s) unless explicit written permission is granted by the corresponding -Copyright Holder. This restriction only applies to the primary font name as -presented to the users. - -4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font -Software shall not be used to promote, endorse or advertise any -Modified Version, except to acknowledge the contribution(s) of the -Copyright Holder(s) and the Author(s) or with their explicit written -permission. - -5) The Font Software, modified or unmodified, in part or in whole, -must be distributed entirely under this license, and must not be -distributed under any other license. The requirement for fonts to -remain under this license does not apply to any document created -using the Font Software. - -TERMINATION -This license becomes null and void if any of the above conditions are -not met. - -DISCLAIMER -THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT -OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE -COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, -INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL -DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING -FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM -OTHER DEALINGS IN THE FONT SOFTWARE. - - -# IBM Type Code - -Copyright 2017 IBM -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. \ No newline at end of file diff --git a/css/demo/css/fonts/iAWriterDuospace-Regular.ttf b/css/demo/css/fonts/iAWriterDuospace-Regular.ttf deleted file mode 100755 index 7e75aa35..00000000 Binary files a/css/demo/css/fonts/iAWriterDuospace-Regular.ttf and /dev/null differ diff --git a/css/demo/demo-script.js b/css/demo/demo-script.js index 0d42a134..04d5f582 100644 --- a/css/demo/demo-script.js +++ b/css/demo/demo-script.js @@ -1,16 +1,27 @@ -document.addEventListener("DOMContentLoaded", function(event) { - var frame = document.getElementById("page"); - var scrollLeft = function() { - var gap = parseInt(window.getComputedStyle(frame.contentWindow.document.documentElement).getPropertyValue("column-gap")); +document.addEventListener("DOMContentLoaded", function() { + const frame = document.getElementById("page"); + + const input = document.createElement("input"); + const label = document.createElement("label"); + + label.className = "rcss-input"; + label.textContent = "Add ReadiumCSS flags and prefs: "; + input.type = "text"; + input.name = "rcss"; + label.appendChild(input); + document.documentElement.appendChild(label); + + const scrollLeft = () => { + const gap = parseInt(window.getComputedStyle(frame.contentWindow.document.documentElement).getPropertyValue("column-gap")); frame.contentWindow.scrollTo(frame.contentWindow.scrollX - frame.contentWindow.innerWidth - gap, 0); }; - var scrollRight = function() { - var gap = parseInt(window.getComputedStyle(frame.contentWindow.document.documentElement).getPropertyValue("column-gap")); + const scrollRight = () => { + const gap = parseInt(window.getComputedStyle(frame.contentWindow.document.documentElement).getPropertyValue("column-gap")); frame.contentWindow.scrollTo(frame.contentWindow.scrollX + frame.contentWindow.innerWidth + gap, 0); }; - document.body.addEventListener('click', function(e) { + document.body.addEventListener("click", function(e) { e.preventDefault(); if (e.clientX > (window.innerWidth / 2)) { scrollRight(); @@ -18,11 +29,16 @@ document.addEventListener("DOMContentLoaded", function(event) { scrollLeft(); } }); - document.body.addEventListener('keydown', function(e) { + + document.body.addEventListener("keydown", function(e) { if (e.keyCode == "39") { scrollRight(); } else if (e.keyCode == "37") { scrollLeft(); } }); -}) \ No newline at end of file + + input.addEventListener("change", (e) => { + frame.contentWindow.document.documentElement.setAttribute("style", e.target.value); + }); +}); \ No newline at end of file diff --git a/css/demo/chrome.html b/css/demo/index.html similarity index 79% rename from css/demo/chrome.html rename to css/demo/index.html index 1d7caa6a..73b38f1d 100644 --- a/css/demo/chrome.html +++ b/css/demo/index.html @@ -29,14 +29,21 @@ -moz-user-select: none; -ms-user-select: none; user-select: none; - /* May help later with Reading modes so that bg can be applied to whole page + /* May help later with theming so that bg can be applied to whole page You need to allowtransparency on the iframe though (and sanitize authors’ CSS) */ background-color: transparent; } + + .rcss-input { + position: absolute; + top: 0; + background-color: rgba(255, 255, 255, 0.5); + padding: 0.5rem; + } - + @@ -1096,6 +1150,14 @@

    Numeric Spacing Values

    customFont = document.getElementById("custom-font"), customMode = document.getElementById("custom-mode"), checkers = document.querySelectorAll("[data-checker]"), + fontWeight = document.getElementById("font-weight"), + fontWeightTarget = document.getElementById("font-weight-target"), + fontWeightValueHolder = document.getElementById("font-weight-value"), + fontWidth = document.getElementById("font-width"), + fontWidthTarget = document.getElementById("font-width-target"), + fontWidthValueHolder = document.getElementById("font-width-value"), + opticalSizing = document.getElementById("optical-sizing"), + opticalSizingTarget = document.getElementById("optical-sizing-target"), downloadLink = document.createElement("a"); var newCustom; @@ -1154,7 +1216,7 @@

    Numeric Spacing Values

    previousLoader.parentElement.removeChild(previousLoader); } - var val = customFont.value, + var val = customFont.value.replace("+", " "), loadFont = val.split(":"); if (loadFont[0] === "google") { @@ -1162,7 +1224,7 @@

    Numeric Spacing Values

    newCustom = loadFont[1]; loader.id = "font-loader"; - loader.innerHTML = "WebFont.load({ google:{families:['"+ loadFont[1] +"']}});"; + loader.innerHTML = "WebFont.load({ google:{families:['"+ val.replace("google:", "") +"']}});"; document.body.appendChild(loader); } else { newCustom = customFont.value; @@ -1174,6 +1236,8 @@

    Numeric Spacing Values

    let checkbox = checkers[i].getElementsByTagName("input")[0]; checkbox.checked = false; } + + resetVariations(); }, false); customMode.addEventListener("change", function (e) { @@ -1186,11 +1250,42 @@

    Numeric Spacing Values

    } }, false); + fontWeight.addEventListener("input", function(e) { + fontWeightTarget.style.setProperty("--font-weight", e.target.value); + fontWeightValueHolder.textContent = e.target.value; + }, false); + + fontWidth.addEventListener("input", function(e) { + fontWidthTarget.style.setProperty("--font-width", e.target.value + "%"); + fontWidthValueHolder.textContent = e.target.value; + }, false); + + opticalSizing.addEventListener("change", function (e) { + if (this.checked) { + opticalSizingTarget.style.setProperty("--optical-sizing", "none"); + } else { + opticalSizingTarget.style.setProperty("--optical-sizing", "auto"); + } + }, false); + downloadLink.addEventListener("click", function(e) { e.preventDefault(); download(); }, false); + function resetVariations() { + fontWeight.value = 400; + fontWeightTarget.style.removeProperty("--font-weight"); + fontWeightValueHolder.textContent = "400"; + + fontWidth.value = 100; + fontWidthTarget.style.removeProperty("--font-width"); + fontWidthValueHolder.textContent = "100"; + + opticalSizing.checked = false; + opticalSizingTarget.style.removeProperty("--optical-sizing"); + }; + function download() { let title = customFont.value, filename = title.split(" ").join("-").toLowerCase() + ".html", diff --git a/package-lock.json b/package-lock.json index 8331d4ec..0e7e6ade 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,21 +1,21 @@ { - "name": "readium-css", - "version": "1.1.0", + "name": "@readium/css", + "version": "2.0.0-beta.25", "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "readium-css", - "version": "1.1.0", + "name": "@readium/css", + "version": "2.0.0-beta.25", "license": "BSD-3-Clause", "devDependencies": { + "@daltontan/postcss-import-json": "^1.1.1", "backstopjs": "^6.3.23", "copyfiles": "^2.4.1", - "express": "^4.19.1", + "express": "^4.21.1", "postcss-alter-property-value": "^1.1.3", "postcss-cli": "^11.0.0", "postcss-css-variables": "^0.19.0", - "postcss-custom-media": "^10.0.4", "postcss-custom-selectors": "^6.0.3", "postcss-discard-comments": "^6.0.2", "postcss-header": "^3.0.3", @@ -123,29 +123,6 @@ "node": ">=4" } }, - "node_modules/@csstools/cascade-layer-name-parser": { - "version": "1.0.9", - "resolved": "https://registry.npmjs.org/@csstools/cascade-layer-name-parser/-/cascade-layer-name-parser-1.0.9.tgz", - "integrity": "sha512-RRqNjxTZDUhx7pxYOBG/AkCVmPS3zYzfE47GEhIGkFuWFTQGJBgWOUUkKNo5MfxIfjDz5/1L3F3rF1oIsYaIpw==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/csstools" - }, - { - "type": "opencollective", - "url": "https://opencollective.com/csstools" - } - ], - "engines": { - "node": "^14 || ^16 || >=18" - }, - "peerDependencies": { - "@csstools/css-parser-algorithms": "^2.6.1", - "@csstools/css-tokenizer": "^2.2.4" - } - }, "node_modules/@csstools/css-parser-algorithms": { "version": "2.6.1", "resolved": "https://registry.npmjs.org/@csstools/css-parser-algorithms/-/css-parser-algorithms-2.6.1.tgz", @@ -232,6 +209,12 @@ "postcss-selector-parser": "^6.0.13" } }, + "node_modules/@daltontan/postcss-import-json": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@daltontan/postcss-import-json/-/postcss-import-json-1.1.1.tgz", + "integrity": "sha512-O00tu73ApgCIQeQ/P+Wm0Vysinq/YRL4rHsx0O42StdFs9MXnQtzpZw0C37CCg+bxBadwKlZowRy0sf4MTMeeA==", + "dev": true + }, "node_modules/@dual-bundle/import-meta-resolve": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/@dual-bundle/import-meta-resolve/-/import-meta-resolve-4.0.0.tgz", @@ -444,15 +427,15 @@ } }, "node_modules/ajv": { - "version": "8.12.0", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.12.0.tgz", - "integrity": "sha512-sRu1kpcO9yLtYxBKvqfTeh9KzZEwO3STyX1HT+4CaDzC6HpTGYhIhPIzj9XuKU7KYDwnaeh5hcOwjy1QuJzBPA==", + "version": "8.18.0", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.18.0.tgz", + "integrity": "sha512-PlXPeEWMXMZ7sPYOHqmDyCJzcfNrUr3fGNKtezX14ykXOEIvyK81d+qydx89KY5O71FKMPaQ2vBfBFI5NHR63A==", "dev": true, "dependencies": { - "fast-deep-equal": "^3.1.1", + "fast-deep-equal": "^3.1.3", + "fast-uri": "^3.0.1", "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2", - "uri-js": "^4.2.2" + "require-from-string": "^2.0.2" }, "funding": { "type": "github", @@ -557,9 +540,9 @@ "dev": true }, "node_modules/backstopjs": { - "version": "6.3.23", - "resolved": "https://registry.npmjs.org/backstopjs/-/backstopjs-6.3.23.tgz", - "integrity": "sha512-GRSth3jEWI0goJ5ETA+D6QsK7ZZi0+qvZ0AAroGoLODCb20Y7NG3gc0Egnf4Qdrqg4D+seJHVjfZwqm3nuYqZg==", + "version": "6.3.25", + "resolved": "https://registry.npmjs.org/backstopjs/-/backstopjs-6.3.25.tgz", + "integrity": "sha512-jy0dxlk45tItXLcj9zjRTCyCa6D27M9OMK5kM8To0ELLclKhI/dWn/igUTMBBMJXe4Kql+CGyDRErMtTv2+40Q==", "dev": true, "dependencies": { "@mirzazeyrek/node-resemble-js": "^1.2.1", @@ -585,7 +568,7 @@ "backstop": "cli/index.js" }, "engines": { - "node": ">=16.0.0 <=20.x.x", + "node": ">=16.0.0", "npm": ">=8.0.0" } }, @@ -596,49 +579,80 @@ "dev": true }, "node_modules/bare-events": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/bare-events/-/bare-events-2.4.2.tgz", - "integrity": "sha512-qMKFd2qG/36aA4GwvKq8MxnPgCQAmBWmSyLWsJcbn8v03wvIPQ/hG1Ms8bPzndZxMDoHpxez5VOS+gC9Yi24/Q==", + "version": "2.5.4", + "resolved": "https://registry.npmjs.org/bare-events/-/bare-events-2.5.4.tgz", + "integrity": "sha512-+gFfDkR8pj4/TrWCGUGWmJIkBwuxPS5F+a5yWjOHQt2hHvNZd5YLzadjmDUtFmMM4y429bnKLa8bYBMHcYdnQA==", "dev": true, + "license": "Apache-2.0", "optional": true }, "node_modules/bare-fs": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/bare-fs/-/bare-fs-2.3.1.tgz", - "integrity": "sha512-W/Hfxc/6VehXlsgFtbB5B4xFcsCl+pAh30cYhoFyXErf6oGrwjh8SwiPAdHgpmWonKuYpZgGywN0SXt7dgsADA==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/bare-fs/-/bare-fs-4.0.2.tgz", + "integrity": "sha512-S5mmkMesiduMqnz51Bfh0Et9EX0aTCJxhsI4bvzFFLs8Z1AV8RDHadfY5CyLwdoLHgXbNBEN1gQcbEtGwuvixw==", "dev": true, + "license": "Apache-2.0", "optional": true, "dependencies": { - "bare-events": "^2.0.0", - "bare-path": "^2.0.0", - "bare-stream": "^2.0.0" + "bare-events": "^2.5.4", + "bare-path": "^3.0.0", + "bare-stream": "^2.6.4" + }, + "engines": { + "bare": ">=1.16.0" + }, + "peerDependencies": { + "bare-buffer": "*" + }, + "peerDependenciesMeta": { + "bare-buffer": { + "optional": true + } } }, "node_modules/bare-os": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/bare-os/-/bare-os-2.4.0.tgz", - "integrity": "sha512-v8DTT08AS/G0F9xrhyLtepoo9EJBJ85FRSMbu1pQUlAf6A8T0tEEQGMVObWeqpjhSPXsE0VGlluFBJu2fdoTNg==", + "version": "3.6.1", + "resolved": "https://registry.npmjs.org/bare-os/-/bare-os-3.6.1.tgz", + "integrity": "sha512-uaIjxokhFidJP+bmmvKSgiMzj2sV5GPHaZVAIktcxcpCyBFFWO+YlikVAdhmUo2vYFvFhOXIAlldqV29L8126g==", "dev": true, - "optional": true + "license": "Apache-2.0", + "optional": true, + "engines": { + "bare": ">=1.14.0" + } }, "node_modules/bare-path": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/bare-path/-/bare-path-2.1.3.tgz", - "integrity": "sha512-lh/eITfU8hrj9Ru5quUp0Io1kJWIk1bTjzo7JH1P5dWmQ2EL4hFUlfI8FonAhSlgIfhn63p84CDY/x+PisgcXA==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/bare-path/-/bare-path-3.0.0.tgz", + "integrity": "sha512-tyfW2cQcB5NN8Saijrhqn0Zh7AnFNsnczRcuWODH0eYAXBsJ5gVxAUuNr7tsHSC6IZ77cA0SitzT+s47kot8Mw==", "dev": true, + "license": "Apache-2.0", "optional": true, "dependencies": { - "bare-os": "^2.1.0" + "bare-os": "^3.0.1" } }, "node_modules/bare-stream": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/bare-stream/-/bare-stream-2.1.3.tgz", - "integrity": "sha512-tiDAH9H/kP+tvNO5sczyn9ZAA7utrSMobyDchsnyyXBuUe2FSQWbxhtuHB8jwpHYYevVo2UJpcmvvjrbHboUUQ==", + "version": "2.6.5", + "resolved": "https://registry.npmjs.org/bare-stream/-/bare-stream-2.6.5.tgz", + "integrity": "sha512-jSmxKJNJmHySi6hC42zlZnq00rga4jjxcgNZjY9N5WlOe/iOoGRtdwGsHzQv2RlH2KOYMwGUXhf2zXd32BA9RA==", "dev": true, + "license": "Apache-2.0", "optional": true, "dependencies": { - "streamx": "^2.18.0" + "streamx": "^2.21.0" + }, + "peerDependencies": { + "bare-buffer": "*", + "bare-events": "*" + }, + "peerDependenciesMeta": { + "bare-buffer": { + "optional": true + }, + "bare-events": { + "optional": true + } } }, "node_modules/base64-js": { @@ -683,33 +697,62 @@ } }, "node_modules/body-parser": { - "version": "1.20.2", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", - "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", + "version": "1.20.4", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.4.tgz", + "integrity": "sha512-ZTgYYLMOXY9qKU/57FAo8F+HA2dGX7bqGc71txDRC1rS4frdFI5R7NhluHxH6M0YItAP0sHB4uqAOcYKxO6uGA==", "dev": true, "dependencies": { - "bytes": "3.1.2", + "bytes": "~3.1.2", "content-type": "~1.0.5", "debug": "2.6.9", "depd": "2.0.0", - "destroy": "1.2.0", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "on-finished": "2.4.1", - "qs": "6.11.0", - "raw-body": "2.5.2", + "destroy": "~1.2.0", + "http-errors": "~2.0.1", + "iconv-lite": "~0.4.24", + "on-finished": "~2.4.1", + "qs": "~6.14.0", + "raw-body": "~2.5.3", "type-is": "~1.6.18", - "unpipe": "1.0.0" + "unpipe": "~1.0.0" }, "engines": { "node": ">= 0.8", "npm": "1.2.8000 || >= 1.4.16" } }, + "node_modules/body-parser/node_modules/http-errors": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.1.tgz", + "integrity": "sha512-4FbRdAX+bSdmo4AUFuS0WNiPz8NgFt+r8ThgNWmlrjQjt1Q7ZR9+zTlce2859x4KSXrwIsaeTqDoKQmtP8pLmQ==", + "dev": true, + "dependencies": { + "depd": "~2.0.0", + "inherits": "~2.0.4", + "setprototypeof": "~1.2.0", + "statuses": "~2.0.2", + "toidentifier": "~1.0.1" + }, + "engines": { + "node": ">= 0.8" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/body-parser/node_modules/statuses": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.2.tgz", + "integrity": "sha512-DvEy55V3DB7uknRo+4iOGT5fP1slR8wQohVdknigZPMpMstaKJQWhwiYBACJE3Ul2pTnATihhBYnRhZQHGBiRw==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, "node_modules/brace-expansion": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "version": "1.1.12", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.12.tgz", + "integrity": "sha512-9T9UjW3r0UW5c1Q7GTwllptXwhvYmEzFhzMfZ9H7FQWt+uZePjZPjBP/W1ZEyZ1twGWom5/56TF4lPcqjnDHcg==", "dev": true, "dependencies": { "balanced-match": "^1.0.0", @@ -770,17 +813,29 @@ "node": ">= 0.8" } }, - "node_modules/call-bind": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.7.tgz", - "integrity": "sha512-GHTSNSYICQ7scH7sZ+M2rFopRoLh8t2bLSW6BbgrtLsahOIB5iyAVJf9GjWK3cYTDaMj4XdBpM1cA6pIS0Kv2w==", + "node_modules/call-bind-apply-helpers": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.2.tgz", + "integrity": "sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==", "dev": true, + "license": "MIT", "dependencies": { - "es-define-property": "^1.0.0", "es-errors": "^1.3.0", - "function-bind": "^1.1.2", - "get-intrinsic": "^1.2.4", - "set-function-length": "^1.2.1" + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/call-bound": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/call-bound/-/call-bound-1.0.4.tgz", + "integrity": "sha512-+ys997U96po4Kx/ABpBCqhA9EuxJaQWDQg7295H4hBphv3IZg0boBKuwYpt4YXp6MZ5AmZQnU/tyMTlRpaSejg==", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind-apply-helpers": "^1.0.2", + "get-intrinsic": "^1.3.0" }, "engines": { "node": ">= 0.4" @@ -948,9 +1003,9 @@ } }, "node_modules/cookie": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", - "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", + "version": "0.7.1", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.7.1.tgz", + "integrity": "sha512-6DnInpx7SJ2AK3+CTUE/ZM0vWTUboZCegxhC2xiIydHR9jNuTAASBrfEpHhiGOZw/nX51bHt6YQl8jsGo4y/0w==", "dev": true, "engines": { "node": ">= 0.6" @@ -1145,23 +1200,6 @@ "ms": "2.0.0" } }, - "node_modules/define-data-property": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz", - "integrity": "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==", - "dev": true, - "dependencies": { - "es-define-property": "^1.0.0", - "es-errors": "^1.3.0", - "gopd": "^1.0.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/degenerator": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/degenerator/-/degenerator-5.0.1.tgz", @@ -1211,9 +1249,9 @@ "dev": true }, "node_modules/diff": { - "version": "3.5.0", - "resolved": "https://registry.npmjs.org/diff/-/diff-3.5.0.tgz", - "integrity": "sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA==", + "version": "3.5.1", + "resolved": "https://registry.npmjs.org/diff/-/diff-3.5.1.tgz", + "integrity": "sha512-Z3u54A8qGyqFOSr2pk0ijYs8mOE9Qz8kTvtKeBI+upoG9j04Sq+oI7W8zAJiQybDcESET8/uIdHzs0p3k4fZlw==", "dev": true, "engines": { "node": ">=0.3.1" @@ -1261,6 +1299,21 @@ "node": ">=4.0.0" } }, + "node_modules/dunder-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz", + "integrity": "sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind-apply-helpers": "^1.0.1", + "es-errors": "^1.3.0", + "gopd": "^1.2.0" + }, + "engines": { + "node": ">= 0.4" + } + }, "node_modules/ee-first": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", @@ -1274,9 +1327,9 @@ "dev": true }, "node_modules/encodeurl": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", - "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", + "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==", "dev": true, "engines": { "node": ">= 0.8" @@ -1310,13 +1363,11 @@ } }, "node_modules/es-define-property": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.0.tgz", - "integrity": "sha512-jxayLKShrEqqzJ0eumQbVhTYQM27CfT1T35+gCgDFoL82JLsXqTJ76zv6A0YLOgEnLUMvLzsDsGIrl8NFpT2gQ==", + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.1.tgz", + "integrity": "sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==", "dev": true, - "dependencies": { - "get-intrinsic": "^1.2.4" - }, + "license": "MIT", "engines": { "node": ">= 0.4" } @@ -1326,6 +1377,20 @@ "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==", "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-object-atoms": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.1.1.tgz", + "integrity": "sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA==", + "dev": true, + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0" + }, "engines": { "node": ">= 0.4" } @@ -1416,45 +1481,50 @@ } }, "node_modules/express": { - "version": "4.19.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", - "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", + "version": "4.22.1", + "resolved": "https://registry.npmjs.org/express/-/express-4.22.1.tgz", + "integrity": "sha512-F2X8g9P1X7uCPZMA3MVf9wcTqlyNp7IhH5qPCI0izhaOIYXaW9L535tGA3qmjRzpH+bZczqq7hVKxTR4NWnu+g==", "dev": true, + "license": "MIT", "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.2", - "content-disposition": "0.5.4", + "body-parser": "~1.20.3", + "content-disposition": "~0.5.4", "content-type": "~1.0.4", - "cookie": "0.6.0", - "cookie-signature": "1.0.6", + "cookie": "~0.7.1", + "cookie-signature": "~1.0.6", "debug": "2.6.9", "depd": "2.0.0", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "etag": "~1.8.1", - "finalhandler": "1.2.0", - "fresh": "0.5.2", - "http-errors": "2.0.0", - "merge-descriptors": "1.0.1", + "finalhandler": "~1.3.1", + "fresh": "~0.5.2", + "http-errors": "~2.0.0", + "merge-descriptors": "1.0.3", "methods": "~1.1.2", - "on-finished": "2.4.1", + "on-finished": "~2.4.1", "parseurl": "~1.3.3", - "path-to-regexp": "0.1.7", + "path-to-regexp": "~0.1.12", "proxy-addr": "~2.0.7", - "qs": "6.11.0", + "qs": "~6.14.0", "range-parser": "~1.2.1", "safe-buffer": "5.2.1", - "send": "0.18.0", - "serve-static": "1.15.0", + "send": "~0.19.0", + "serve-static": "~1.16.2", "setprototypeof": "1.2.0", - "statuses": "2.0.1", + "statuses": "~2.0.1", "type-is": "~1.6.18", "utils-merge": "1.0.1", "vary": "~1.1.2" }, "engines": { "node": ">= 0.10.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" } }, "node_modules/extend": { @@ -1534,6 +1604,22 @@ "node": ">=8.6.0" } }, + "node_modules/fast-uri": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-3.1.0.tgz", + "integrity": "sha512-iPeeDKJSWf4IEOasVVrknXpaBV0IApz/gp7S2bb7Z4Lljbl2MGJRqInZiUrQwV16cpzw/D3S5j5Julj/gT52AA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/fastify" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/fastify" + } + ] + }, "node_modules/fastest-levenshtein": { "version": "1.0.16", "resolved": "https://registry.npmjs.org/fastest-levenshtein/-/fastest-levenshtein-1.0.16.tgz", @@ -1586,13 +1672,13 @@ } }, "node_modules/finalhandler": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.2.0.tgz", - "integrity": "sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg==", + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.3.1.tgz", + "integrity": "sha512-6BN9trH7bp3qvnrRyzsBz+g3lZxTNZTbVO2EV1CS0WIcDbawYVdYvGflME/9QP0h0pYlCDBCTjYa9nZzMDpyxQ==", "dev": true, "dependencies": { "debug": "2.6.9", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "on-finished": "2.4.1", "parseurl": "~1.3.3", @@ -1693,16 +1779,22 @@ } }, "node_modules/get-intrinsic": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.4.tgz", - "integrity": "sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ==", + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.3.0.tgz", + "integrity": "sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ==", "dev": true, + "license": "MIT", "dependencies": { + "call-bind-apply-helpers": "^1.0.2", + "es-define-property": "^1.0.1", "es-errors": "^1.3.0", + "es-object-atoms": "^1.1.1", "function-bind": "^1.1.2", - "has-proto": "^1.0.1", - "has-symbols": "^1.0.3", - "hasown": "^2.0.0" + "get-proto": "^1.0.1", + "gopd": "^1.2.0", + "has-symbols": "^1.1.0", + "hasown": "^2.0.2", + "math-intrinsics": "^1.1.0" }, "engines": { "node": ">= 0.4" @@ -1711,6 +1803,20 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/get-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/get-proto/-/get-proto-1.0.1.tgz", + "integrity": "sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==", + "dev": true, + "license": "MIT", + "dependencies": { + "dunder-proto": "^1.0.1", + "es-object-atoms": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, "node_modules/get-stdin": { "version": "9.0.0", "resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-9.0.0.tgz", @@ -1861,12 +1967,13 @@ "dev": true }, "node_modules/gopd": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", - "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.2.0.tgz", + "integrity": "sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==", "dev": true, - "dependencies": { - "get-intrinsic": "^1.1.3" + "license": "MIT", + "engines": { + "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" @@ -1887,35 +1994,12 @@ "node": ">=8" } }, - "node_modules/has-property-descriptors": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz", - "integrity": "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==", - "dev": true, - "dependencies": { - "es-define-property": "^1.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/has-proto": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.3.tgz", - "integrity": "sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==", - "dev": true, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/has-symbols": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", - "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.1.0.tgz", + "integrity": "sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==", "dev": true, + "license": "MIT", "engines": { "node": ">= 0.4" }, @@ -2266,10 +2350,11 @@ "dev": true }, "node_modules/js-yaml": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", - "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.1.tgz", + "integrity": "sha512-qQKT4zQxXl8lLwBtHMWwaTcGfFOZviOJet3Oy/xmGk2gZH677CJM9EvtfdSkgWcATZhj/55JZ0rmy3myCT5lsA==", "dev": true, + "license": "MIT", "dependencies": { "argparse": "^2.0.1" }, @@ -2377,10 +2462,11 @@ "dev": true }, "node_modules/lodash": { - "version": "4.17.21", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", - "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", - "dev": true + "version": "4.17.23", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.23.tgz", + "integrity": "sha512-LgVTMpQtIopCi79SJeDiP0TfWi5CNEc/L/aRdTh3yIvmZXTnheWpKjSZhnvMl8iXbC1tFg9gdHHDMLoV7CnG+w==", + "dev": true, + "license": "MIT" }, "node_modules/lodash.truncate": { "version": "4.4.2", @@ -2412,6 +2498,16 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/math-intrinsics": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/math-intrinsics/-/math-intrinsics-1.1.0.tgz", + "integrity": "sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, "node_modules/mathml-tag-names": { "version": "2.1.3", "resolved": "https://registry.npmjs.org/mathml-tag-names/-/mathml-tag-names-2.1.3.tgz", @@ -2450,10 +2546,13 @@ } }, "node_modules/merge-descriptors": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", - "integrity": "sha512-cCi6g3/Zr1iqQi6ySbseM1Xvooa98N0w31jzUYrXPX2xqObmFGHJ0tQ5u74H3mVh7wLouTseZyYIq39g8cNp1w==", - "dev": true + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.3.tgz", + "integrity": "sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } }, "node_modules/merge2": { "version": "1.4.1", @@ -2565,9 +2664,9 @@ "dev": true }, "node_modules/nanoid": { - "version": "3.3.7", - "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.7.tgz", - "integrity": "sha512-eSRppjcPIatRIMC1U6UngP8XFcz8MQWGQdt1MTBQ7NaAmvXDfvNxbvWV3x2y6CdEUciCSsDHDQZbhYaB8QEo2g==", + "version": "3.3.8", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.8.tgz", + "integrity": "sha512-WNLf5Sd8oZxOm+TzppcYk8gVOgP+l58xNy58D0nbUnOxOWRWvlcCV4kUF7ltmI6PsrLl/BgKEyS4mqsGChFN0w==", "dev": true, "funding": [ { @@ -2629,10 +2728,14 @@ } }, "node_modules/object-inspect": { - "version": "1.13.1", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.1.tgz", - "integrity": "sha512-5qoj1RUiKOMsCCNLV1CBiPYE10sziTsnmNxkAI/rZhiD63CF7IqdFGC/XzjWjpSgLf0LxXX3bDFIh0E18f6UhQ==", + "version": "1.13.4", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.4.tgz", + "integrity": "sha512-W67iLl4J2EXEGTbfeHCffrjDfitvLANg0UlX3wFUUSTx92KXRFegMHUVgSqE+wvhAbi4WqjGg9czysTV2Epbew==", "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, "funding": { "url": "https://github.com/sponsors/ljharb" } @@ -2812,9 +2915,9 @@ "dev": true }, "node_modules/path-to-regexp": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", - "integrity": "sha512-5DFkuoqlv1uYQKxy8omFBeJPQcdoE07Kv2sferDCrAq1ohOU+MSDswDIbnx3YAM60qIOnYa53wBhXW0EbMonrQ==", + "version": "0.1.12", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.12.tgz", + "integrity": "sha512-RA1GjUVMnvYFxuqovrEqZoxxW5NUZqbwKtYz/Tt7nXerk0LbLblQmrsgdeOxV5SFHf0UDggjS/bSeOZwt1pmEQ==", "dev": true }, "node_modules/path-type": { @@ -2884,33 +2987,33 @@ } }, "node_modules/playwright": { - "version": "1.43.1", - "resolved": "https://registry.npmjs.org/playwright/-/playwright-1.43.1.tgz", - "integrity": "sha512-V7SoH0ai2kNt1Md9E3Gwas5B9m8KR2GVvwZnAI6Pg0m3sh7UvgiYhRrhsziCmqMJNouPckiOhk8T+9bSAK0VIA==", + "version": "1.56.1", + "resolved": "https://registry.npmjs.org/playwright/-/playwright-1.56.1.tgz", + "integrity": "sha512-aFi5B0WovBHTEvpM3DzXTUaeN6eN0qWnTkKx4NQaH4Wvcmc153PdaY2UBdSYKaGYw+UyWXSVyxDUg5DoPEttjw==", "dev": true, "dependencies": { - "playwright-core": "1.43.1" + "playwright-core": "1.56.1" }, "bin": { "playwright": "cli.js" }, "engines": { - "node": ">=16" + "node": ">=18" }, "optionalDependencies": { "fsevents": "2.3.2" } }, "node_modules/playwright-core": { - "version": "1.43.1", - "resolved": "https://registry.npmjs.org/playwright-core/-/playwright-core-1.43.1.tgz", - "integrity": "sha512-EI36Mto2Vrx6VF7rm708qSnesVQKbxEWvPrfA1IPY6HgczBplDx7ENtx+K2n4kJ41sLLkuGfmb0ZLSSXlDhqPg==", + "version": "1.56.1", + "resolved": "https://registry.npmjs.org/playwright-core/-/playwright-core-1.56.1.tgz", + "integrity": "sha512-hutraynyn31F+Bifme+Ps9Vq59hKuUCz7H1kDOcBs+2oGguKkWTU50bBWrtz34OUWmIwpBTWDxaRPXrIXkgvmQ==", "dev": true, "bin": { "playwright-core": "cli.js" }, "engines": { - "node": ">=16" + "node": ">=18" } }, "node_modules/pngjs": { @@ -3028,34 +3131,6 @@ "postcss": "^8.2.6" } }, - "node_modules/postcss-custom-media": { - "version": "10.0.4", - "resolved": "https://registry.npmjs.org/postcss-custom-media/-/postcss-custom-media-10.0.4.tgz", - "integrity": "sha512-Ubs7O3wj2prghaKRa68VHBvuy3KnTQ0zbGwqDYY1mntxJD0QL2AeiAy+AMfl3HBedTCVr2IcFNktwty9YpSskA==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/csstools" - }, - { - "type": "opencollective", - "url": "https://opencollective.com/csstools" - } - ], - "dependencies": { - "@csstools/cascade-layer-name-parser": "^1.0.9", - "@csstools/css-parser-algorithms": "^2.6.1", - "@csstools/css-tokenizer": "^2.2.4", - "@csstools/media-query-list-parser": "^2.1.9" - }, - "engines": { - "node": "^14 || ^16 || >=18" - }, - "peerDependencies": { - "postcss": "^8.4" - } - }, "node_modules/postcss-custom-selectors": { "version": "6.0.3", "resolved": "https://registry.npmjs.org/postcss-custom-selectors/-/postcss-custom-selectors-6.0.3.tgz", @@ -3338,15 +3413,6 @@ "once": "^1.3.1" } }, - "node_modules/punycode": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", - "integrity": "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==", - "dev": true, - "engines": { - "node": ">=6" - } - }, "node_modules/puppeteer": { "version": "22.15.0", "resolved": "https://registry.npmjs.org/puppeteer/-/puppeteer-22.15.0.tgz", @@ -3406,12 +3472,12 @@ "dev": true }, "node_modules/qs": { - "version": "6.11.0", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.11.0.tgz", - "integrity": "sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q==", + "version": "6.14.2", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.14.2.tgz", + "integrity": "sha512-V/yCWTTF7VJ9hIh18Ugr2zhJMP01MY7c5kh4J870L7imm6/DIzBsNLTXzMwUA3yZ5b/KBqLx8Kp3uRvd7xSe3Q==", "dev": true, "dependencies": { - "side-channel": "^1.0.4" + "side-channel": "^1.1.0" }, "engines": { "node": ">=0.6" @@ -3440,12 +3506,6 @@ } ] }, - "node_modules/queue-tick": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/queue-tick/-/queue-tick-1.0.1.tgz", - "integrity": "sha512-kJt5qhMxoszgU/62PLP1CJytzd2NKetjSRnyuj31fDd3Rlcz3fzlFdFLD1SItunPwyqEOkca6GbV612BWfaBag==", - "dev": true - }, "node_modules/range-parser": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz", @@ -3456,20 +3516,49 @@ } }, "node_modules/raw-body": { - "version": "2.5.2", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.2.tgz", - "integrity": "sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA==", + "version": "2.5.3", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.3.tgz", + "integrity": "sha512-s4VSOf6yN0rvbRZGxs8Om5CWj6seneMwK3oDb4lWDH0UPhWcxwOWw5+qk24bxq87szX1ydrwylIOp2uG1ojUpA==", "dev": true, "dependencies": { - "bytes": "3.1.2", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "unpipe": "1.0.0" + "bytes": "~3.1.2", + "http-errors": "~2.0.1", + "iconv-lite": "~0.4.24", + "unpipe": "~1.0.0" }, "engines": { "node": ">= 0.8" } }, + "node_modules/raw-body/node_modules/http-errors": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.1.tgz", + "integrity": "sha512-4FbRdAX+bSdmo4AUFuS0WNiPz8NgFt+r8ThgNWmlrjQjt1Q7ZR9+zTlce2859x4KSXrwIsaeTqDoKQmtP8pLmQ==", + "dev": true, + "dependencies": { + "depd": "~2.0.0", + "inherits": "~2.0.4", + "setprototypeof": "~1.2.0", + "statuses": "~2.0.2", + "toidentifier": "~1.0.1" + }, + "engines": { + "node": ">= 0.8" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/raw-body/node_modules/statuses": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.2.tgz", + "integrity": "sha512-DvEy55V3DB7uknRo+4iOGT5fP1slR8wQohVdknigZPMpMstaKJQWhwiYBACJE3Ul2pTnATihhBYnRhZQHGBiRw==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, "node_modules/read-cache": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/read-cache/-/read-cache-1.0.0.tgz", @@ -3628,9 +3717,9 @@ } }, "node_modules/send": { - "version": "0.18.0", - "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", - "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "version": "0.19.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.19.0.tgz", + "integrity": "sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==", "dev": true, "dependencies": { "debug": "2.6.9", @@ -3651,6 +3740,15 @@ "node": ">= 0.8.0" } }, + "node_modules/send/node_modules/encodeurl": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", + "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, "node_modules/send/node_modules/ms": { "version": "2.1.3", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", @@ -3658,53 +3756,94 @@ "dev": true }, "node_modules/serve-static": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.15.0.tgz", - "integrity": "sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==", + "version": "1.16.2", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.16.2.tgz", + "integrity": "sha512-VqpjJZKadQB/PEbEwvFdO43Ax5dFBZ2UECszz8bQ7pi7wt//PWe1P6MN7eCnjsatYtBT6EuiClbjSWP2WrIoTw==", "dev": true, "dependencies": { - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "parseurl": "~1.3.3", - "send": "0.18.0" + "send": "0.19.0" }, "engines": { "node": ">= 0.8.0" } }, - "node_modules/set-function-length": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", - "integrity": "sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==", + "node_modules/setprototypeof": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", + "integrity": "sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==", + "dev": true + }, + "node_modules/side-channel": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.1.0.tgz", + "integrity": "sha512-ZX99e6tRweoUXqR+VBrslhda51Nh5MTQwou5tnUDgbtyM0dBgmhEDtWGP/xbKn6hqfPRHujUNwz5fy/wbbhnpw==", "dev": true, + "license": "MIT", "dependencies": { - "define-data-property": "^1.1.4", "es-errors": "^1.3.0", - "function-bind": "^1.1.2", - "get-intrinsic": "^1.2.4", - "gopd": "^1.0.1", - "has-property-descriptors": "^1.0.2" + "object-inspect": "^1.13.3", + "side-channel-list": "^1.0.0", + "side-channel-map": "^1.0.1", + "side-channel-weakmap": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel-list": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/side-channel-list/-/side-channel-list-1.0.0.tgz", + "integrity": "sha512-FCLHtRD/gnpCiCHEiJLOwdmFP+wzCmDEkc9y7NsYxeF4u7Btsn1ZuwgwJGxImImHicJArLP4R0yX4c2KCrMrTA==", + "dev": true, + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "object-inspect": "^1.13.3" }, "engines": { "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/setprototypeof": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", - "integrity": "sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==", - "dev": true + "node_modules/side-channel-map": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/side-channel-map/-/side-channel-map-1.0.1.tgz", + "integrity": "sha512-VCjCNfgMsby3tTdo02nbjtM/ewra6jPHmpThenkTYh8pG9ucZ/1P8So4u4FGBek/BjpOVsDCMoLA/iuBKIFXRA==", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.2", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.5", + "object-inspect": "^1.13.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } }, - "node_modules/side-channel": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.6.tgz", - "integrity": "sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA==", + "node_modules/side-channel-weakmap": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/side-channel-weakmap/-/side-channel-weakmap-1.0.2.tgz", + "integrity": "sha512-WPS/HvHQTYnHisLo9McqBHOJk2FkHO/tlpvldyrnem4aeQp4hai3gythswg6p01oSoTl58rcpiFAjF2br2Ak2A==", "dev": true, + "license": "MIT", "dependencies": { - "call-bind": "^1.0.7", + "call-bound": "^1.0.2", "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.4", - "object-inspect": "^1.13.1" + "get-intrinsic": "^1.2.5", + "object-inspect": "^1.13.3", + "side-channel-map": "^1.0.1" }, "engines": { "node": ">= 0.4" @@ -3850,13 +3989,13 @@ } }, "node_modules/streamx": { - "version": "2.18.0", - "resolved": "https://registry.npmjs.org/streamx/-/streamx-2.18.0.tgz", - "integrity": "sha512-LLUC1TWdjVdn1weXGcSxyTR3T4+acB6tVGXT95y0nGbca4t4o/ng1wKAGTljm9VicuCVLvRlqFYXYy5GwgM7sQ==", + "version": "2.22.0", + "resolved": "https://registry.npmjs.org/streamx/-/streamx-2.22.0.tgz", + "integrity": "sha512-sLh1evHOzBy/iWRiR6d1zRcLao4gGZr3C1kzNz4fopCOKJb6xD9ub8Mpi9Mr1R6id5o43S+d93fI48UC5uM9aw==", "dev": true, + "license": "MIT", "dependencies": { "fast-fifo": "^1.3.2", - "queue-tick": "^1.0.1", "text-decoder": "^1.1.0" }, "optionalDependencies": { @@ -4133,17 +4272,18 @@ } }, "node_modules/tar-fs": { - "version": "3.0.6", - "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-3.0.6.tgz", - "integrity": "sha512-iokBDQQkUyeXhgPYaZxmczGPhnhXZ0CmrqI+MOb/WFGS9DW5wnfrLgtjUJBvz50vQ3qfRwJ62QVoCFu8mPVu5w==", + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-3.1.1.tgz", + "integrity": "sha512-LZA0oaPOc2fVo82Txf3gw+AkEd38szODlptMYejQUhndHMLQ9M059uXR+AfS7DNo0NpINvSqDsvyaCrBVkptWg==", "dev": true, + "license": "MIT", "dependencies": { "pump": "^3.0.0", "tar-stream": "^3.1.5" }, "optionalDependencies": { - "bare-fs": "^2.1.1", - "bare-path": "^2.1.0" + "bare-fs": "^4.0.1", + "bare-path": "^3.0.0" } }, "node_modules/tar-stream": { @@ -4333,15 +4473,6 @@ "node": ">=8" } }, - "node_modules/uri-js": { - "version": "4.4.1", - "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz", - "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==", - "dev": true, - "dependencies": { - "punycode": "^2.1.0" - } - }, "node_modules/urlpattern-polyfill": { "version": "10.0.0", "resolved": "https://registry.npmjs.org/urlpattern-polyfill/-/urlpattern-polyfill-10.0.0.tgz", diff --git a/package.json b/package.json index 02213de1..cd5cd7dd 100644 --- a/package.json +++ b/package.json @@ -1,8 +1,8 @@ { - "name": "readium-css", + "name": "@readium/css", "description": "A set of reference stylesheets for EPUB Reading Systems", - "version": "1.1.0", - "homepage": "https://github.com/readium/readium-css", + "version": "2.0.0", + "homepage": "https://github.com/readium/css", "license": "BSD-3-Clause", "keywords": [ "epub", @@ -18,20 +18,26 @@ }, "repository": { "type": "git", - "url": "https://github.com/readium/readium-css.git" + "url": "https://github.com/readium/css.git" }, "bugs": { - "url": "https://github.com/readium/readium-css/issues" + "url": "https://github.com/readium/css/issues" }, - "main": "css/ReadiumCSS-config.css", + "files": [ + "css/**/*", + "!css/*.js", + "!css/demo/**/*", + "!css/src/**/*", + "!css/ReadiumCSS-config.css" + ], "devDependencies": { + "@daltontan/postcss-import-json": "^1.1.1", "backstopjs": "^6.3.23", "copyfiles": "^2.4.1", - "express": "^4.19.1", + "express": "^4.21.1", "postcss-alter-property-value": "^1.1.3", "postcss-cli": "^11.0.0", "postcss-css-variables": "^0.19.0", - "postcss-custom-media": "^10.0.4", "postcss-custom-selectors": "^6.0.3", "postcss-discard-comments": "^6.0.2", "postcss-header": "^3.0.3", @@ -40,14 +46,15 @@ "stylelint": "^16.4.0" }, "scripts": { - "build": "npm run build:ltr && npm run build:rtl && npm run build:cjk && npm run build:vertical && npm run copyPatches", + "build": "npm run build:ltr && npm run build:rtl && npm run build:cjk && npm run build:vertical && npm run build:web && npm run copyPatches", + "build:web": "postcss css/src/ReadiumCSS-webPub.css -o css/dist/webPub/ReadiumCSS-webPub.css", "build:ltr": "postcss css/src/ReadiumCSS-before.css -o css/dist/ReadiumCSS-before.css && postcss css/src/ReadiumCSS-default.css -o css/dist/ReadiumCSS-default.css && postcss css/src/ReadiumCSS-after.css -o css/dist/ReadiumCSS-after.css", "build:rtl": "postcss css/src/ReadiumCSS-before-rtl.css -o css/dist/rtl/ReadiumCSS-before.css && postcss css/src/ReadiumCSS-default-rtl.css -o css/dist/rtl/ReadiumCSS-default.css && postcss css/src/ReadiumCSS-after-rtl.css -o css/dist/rtl/ReadiumCSS-after.css", "build:cjk": "postcss css/src/ReadiumCSS-before-cjk-horizontal.css -o css/dist/cjk-horizontal/ReadiumCSS-before.css && postcss css/src/ReadiumCSS-default-cjk-horizontal.css -o css/dist/cjk-horizontal/ReadiumCSS-default.css && postcss css/src/ReadiumCSS-after-cjk-horizontal.css -o css/dist/cjk-horizontal/ReadiumCSS-after.css", "build:vertical": "postcss css/src/ReadiumCSS-before-cjk-vertical.css -o css/dist/cjk-vertical/ReadiumCSS-before.css && postcss css/src/ReadiumCSS-default-cjk-vertical.css -o css/dist/cjk-vertical/ReadiumCSS-default.css && postcss css/src/ReadiumCSS-after-cjk-vertical.css -o css/dist/cjk-vertical/ReadiumCSS-after.css", - "copyPatches": "copyfiles -f css/src/ReadiumCSS-ebpaj_fonts_patch.css css/dist", + "copyPatches": "copyfiles -u 2 css/src/ReadiumCSS-ebpaj_fonts_patch.css css/dist", "start": "node \"./server.js\"", - "test": "npm start & backstop test && pkill -9 -f \"node ./server.js\" && echo '\nVisual Regression testing has been completed.\n'", + "test": "npm run build && (npm start & for i in {1..10}; do if curl -s http://localhost:8000 >/dev/null; then backstop test; pkill -f \"node ./server.js\"; echo '\\nVisual Regression testing has been completed.\\n'; exit 0; fi; sleep 1; done; echo 'Failed to start server'; exit 1)", "test:ref": "npm start & backstop reference && pkill -9 -f \"node ./server.js\" && echo '\nVisual Regression references have been generated.\n'", "test:approve": "backstop approve" } diff --git a/server.js b/server.js index f6e2dee3..4c29095e 100644 --- a/server.js +++ b/server.js @@ -14,4 +14,6 @@ httpServer.listen(httpPort, (err) => { }); app.use("/tests", express.static(__dirname + "/tests")); -app.use("/css/dist", express.static(__dirname + "/css/dist")); \ No newline at end of file +app.use("/css/demo", express.static(__dirname + "/css/demo")); +app.use("/css/dist", express.static(__dirname + "/css/dist")); +app.use("/docs/utils", express.static(__dirname + "/docs/utils")); \ No newline at end of file diff --git a/tests/a11y-custom.html b/tests/a11y-custom.html index 5b8fd0a1..70d08275 100644 --- a/tests/a11y-custom.html +++ b/tests/a11y-custom.html @@ -1,5 +1,5 @@ - + Test diff --git a/tests/a11y-font.html b/tests/a11y-font.html index add94cfd..91e33d5a 100644 --- a/tests/a11y-font.html +++ b/tests/a11y-font.html @@ -1,5 +1,5 @@ - + Test diff --git a/tests/a11y-normalize.html b/tests/a11y-normalize.html index 2dea8398..7495857e 100644 --- a/tests/a11y-normalize.html +++ b/tests/a11y-normalize.html @@ -1,5 +1,5 @@ - + Test diff --git a/tests/arabic-ligatures.html b/tests/arabic-ligatures.html index 209c2699..eb15635e 100644 --- a/tests/arabic-ligatures.html +++ b/tests/arabic-ligatures.html @@ -1,5 +1,5 @@ - + Test diff --git a/tests/assets/fonts/Amstelvar-Roman.ttf b/tests/assets/fonts/Amstelvar-Roman.ttf new file mode 100644 index 00000000..062b4a45 Binary files /dev/null and b/tests/assets/fonts/Amstelvar-Roman.ttf differ diff --git a/css/dist/fonts/LICENSE-AccessibleDfa b/tests/assets/fonts/Amstelvar-license.txt old mode 100755 new mode 100644 similarity index 96% rename from css/dist/fonts/LICENSE-AccessibleDfa rename to tests/assets/fonts/Amstelvar-license.txt index bf56c051..b5b20c88 --- a/css/dist/fonts/LICENSE-AccessibleDfa +++ b/tests/assets/fonts/Amstelvar-license.txt @@ -1,95 +1,93 @@ -Copyright (c) Orange 2015, www.orange.com -with Reserved Font Name Accessible-Dfa. - -This Font Software is licensed under the SIL Open Font License, Version 1.1. -This license is copied below, and is also available with a FAQ at: -http://scripts.sil.org/OFL - - ------------------------------------------------------------ -SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 ------------------------------------------------------------ - -PREAMBLE -The goals of the Open Font License (OFL) are to stimulate worldwide -development of collaborative font projects, to support the font creation -efforts of academic and linguistic communities, and to provide a free and -open framework in which fonts may be shared and improved in partnership -with others. - -The OFL allows the licensed fonts to be used, studied, modified and -redistributed freely as long as they are not sold by themselves. The -fonts, including any derivative works, can be bundled, embedded, -redistributed and/or sold with any software provided that any reserved -names are not used by derivative works. The fonts and derivatives, -however, cannot be released under any other type of license. The -requirement for fonts to remain under this license does not apply -to any document created using the fonts or their derivatives. - -DEFINITIONS -"Font Software" refers to the set of files released by the Copyright -Holder(s) under this license and clearly marked as such. This may -include source files, build scripts and documentation. - -"Reserved Font Name" refers to any names specified as such after the -copyright statement(s). - -"Original Version" refers to the collection of Font Software components as -distributed by the Copyright Holder(s). - -"Modified Version" refers to any derivative made by adding to, deleting, -or substituting -- in part or in whole -- any of the components of the -Original Version, by changing formats or by porting the Font Software to a -new environment. - -"Author" refers to any designer, engineer, programmer, technical -writer or other person who contributed to the Font Software. - -PERMISSION & CONDITIONS -Permission is hereby granted, free of charge, to any person obtaining -a copy of the Font Software, to use, study, copy, merge, embed, modify, -redistribute, and sell modified and unmodified copies of the Font -Software, subject to the following conditions: - -1) Neither the Font Software nor any of its individual components, -in Original or Modified Versions, may be sold by itself. - -2) Original or Modified Versions of the Font Software may be bundled, -redistributed and/or sold with any software, provided that each copy -contains the above copyright notice and this license. These can be -included either as stand-alone text files, human-readable headers or -in the appropriate machine-readable metadata fields within text or -binary files as long as those fields can be easily viewed by the user. - -3) No Modified Version of the Font Software may use the Reserved Font -Name(s) unless explicit written permission is granted by the corresponding -Copyright Holder. This restriction only applies to the primary font name as -presented to the users. - -4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font -Software shall not be used to promote, endorse or advertise any -Modified Version, except to acknowledge the contribution(s) of the -Copyright Holder(s) and the Author(s) or with their explicit written -permission. - -5) The Font Software, modified or unmodified, in part or in whole, -must be distributed entirely under this license, and must not be -distributed under any other license. The requirement for fonts to -remain under this license does not apply to any document created -using the Font Software. - -TERMINATION -This license becomes null and void if any of the above conditions are -not met. - -DISCLAIMER -THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT -OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE -COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, -INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL -DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING -FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM -OTHER DEALINGS IN THE FONT SOFTWARE. - +Copyright 2016 The Amstelvar Project Authors (info@fontbureau.com) + +This Font Software is licensed under the SIL Open Font License, Version 1.1. +This license is copied below, and is also available with a FAQ at: +http://scripts.sil.org/OFL + + +----------------------------------------------------------- +SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 +----------------------------------------------------------- + +PREAMBLE +The goals of the Open Font License (OFL) are to stimulate worldwide +development of collaborative font projects, to support the font creation +efforts of academic and linguistic communities, and to provide a free and +open framework in which fonts may be shared and improved in partnership +with others. + +The OFL allows the licensed fonts to be used, studied, modified and +redistributed freely as long as they are not sold by themselves. The +fonts, including any derivative works, can be bundled, embedded, +redistributed and/or sold with any software provided that any reserved +names are not used by derivative works. The fonts and derivatives, +however, cannot be released under any other type of license. The +requirement for fonts to remain under this license does not apply +to any document created using the fonts or their derivatives. + +DEFINITIONS +"Font Software" refers to the set of files released by the Copyright +Holder(s) under this license and clearly marked as such. This may +include source files, build scripts and documentation. + +"Reserved Font Name" refers to any names specified as such after the +copyright statement(s). + +"Original Version" refers to the collection of Font Software components as +distributed by the Copyright Holder(s). + +"Modified Version" refers to any derivative made by adding to, deleting, +or substituting -- in part or in whole -- any of the components of the +Original Version, by changing formats or by porting the Font Software to a +new environment. + +"Author" refers to any designer, engineer, programmer, technical +writer or other person who contributed to the Font Software. + +PERMISSION & CONDITIONS +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Font Software, to use, study, copy, merge, embed, modify, +redistribute, and sell modified and unmodified copies of the Font +Software, subject to the following conditions: + +1) Neither the Font Software nor any of its individual components, +in Original or Modified Versions, may be sold by itself. + +2) Original or Modified Versions of the Font Software may be bundled, +redistributed and/or sold with any software, provided that each copy +contains the above copyright notice and this license. These can be +included either as stand-alone text files, human-readable headers or +in the appropriate machine-readable metadata fields within text or +binary files as long as those fields can be easily viewed by the user. + +3) No Modified Version of the Font Software may use the Reserved Font +Name(s) unless explicit written permission is granted by the corresponding +Copyright Holder. This restriction only applies to the primary font name as +presented to the users. + +4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font +Software shall not be used to promote, endorse or advertise any +Modified Version, except to acknowledge the contribution(s) of the +Copyright Holder(s) and the Author(s) or with their explicit written +permission. + +5) The Font Software, modified or unmodified, in part or in whole, +must be distributed entirely under this license, and must not be +distributed under any other license. The requirement for fonts to +remain under this license does not apply to any document created +using the Font Software. + +TERMINATION +This license becomes null and void if any of the above conditions are +not met. + +DISCLAIMER +THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT +OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE +COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL +DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM +OTHER DEALINGS IN THE FONT SOFTWARE. diff --git a/tests/assets/fonts/Amstelvar.css b/tests/assets/fonts/Amstelvar.css new file mode 100644 index 00000000..082231d0 --- /dev/null +++ b/tests/assets/fonts/Amstelvar.css @@ -0,0 +1,7 @@ +@font-face { + font-family: "Amstelvar"; + src: url(Amstelvar-Roman.ttf) format("truetype"); + font-stretch: 50% 125%; + font-style: normal; + font-weight: 100 1000; +} \ No newline at end of file diff --git a/css/demo/css/fonts/LICENSE-AccessibleDfa b/tests/assets/fonts/RobotoFlex-license.txt old mode 100755 new mode 100644 similarity index 97% rename from css/demo/css/fonts/LICENSE-AccessibleDfa rename to tests/assets/fonts/RobotoFlex-license.txt index bf56c051..5530c572 --- a/css/demo/css/fonts/LICENSE-AccessibleDfa +++ b/tests/assets/fonts/RobotoFlex-license.txt @@ -1,5 +1,4 @@ -Copyright (c) Orange 2015, www.orange.com -with Reserved Font Name Accessible-Dfa. +Copyright 2011 The Roboto Flex Project Authors (https://github.com/googlefonts/roboto-flex) This Font Software is licensed under the SIL Open Font License, Version 1.1. This license is copied below, and is also available with a FAQ at: @@ -92,4 +91,3 @@ INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE. - diff --git a/tests/assets/fonts/RobotoFlex.css b/tests/assets/fonts/RobotoFlex.css new file mode 100644 index 00000000..e64a71d2 --- /dev/null +++ b/tests/assets/fonts/RobotoFlex.css @@ -0,0 +1,7 @@ +@font-face { + font-family: "RobotoFlex"; + src: url(RobotoFlex.ttf) format("truetype"); + font-stretch: 25% 151%; + font-style: normal; + font-weight: 100 1000; +} \ No newline at end of file diff --git a/tests/assets/fonts/RobotoFlex.ttf b/tests/assets/fonts/RobotoFlex.ttf new file mode 100644 index 00000000..c1d8ff7c Binary files /dev/null and b/tests/assets/fonts/RobotoFlex.ttf differ diff --git a/tests/base.html b/tests/base.html index 71679244..15f92bea 100644 --- a/tests/base.html +++ b/tests/base.html @@ -14,9 +14,9 @@

    CHAPTER 1. Loomings.

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    - test if mix blend mode works in sepia, and invert in night mode + test if gaiji work -
    The image above should blend in sepia mode and inverted in night mode.
    +
    The image above can be used to test gaiji.

    There now is your insular city of the Manhattoes, belted round by wharves as Indian isles by coral reefs—commerce surrounds it with her surf. Right and left, the streets take you waterward. Its extreme downtown is the battery, where that noble mole is washed by waves, and cooled by breezes, which a few hours previous were out of sight of land. Look at the crowds of water-gazers there.

    diff --git a/tests/blend-filter.html b/tests/blend-filter.html new file mode 100644 index 00000000..850122c9 --- /dev/null +++ b/tests/blend-filter.html @@ -0,0 +1,24 @@ + + + + Test + + + + + + + +

    CHAPTER 1. Loomings.

    + +

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    + +
    + test if mix blend mode works with a custom background-color + +
    The image above should blend with the background-color.
    +
    + +

    There now is your insular city of the Manhattoes, belted round by wharves as Indian isles by coral reefs—commerce surrounds it with her surf. Right and left, the streets take you waterward. Its extreme downtown is the battery, where that noble mole is washed by waves, and cooled by breezes, which a few hours previous were out of sight of land. Look at the crowds of water-gazers there.

    + + \ No newline at end of file diff --git a/tests/sepia.html b/tests/cols-3.html similarity index 61% rename from tests/sepia.html rename to tests/cols-3.html index 44d0aba4..37845395 100644 --- a/tests/sepia.html +++ b/tests/cols-3.html @@ -1,5 +1,5 @@ - + Test @@ -9,50 +9,14 @@ - - - - - - - - - - - - - - - - - - - - - - - - - -

    CHAPTER 1. Loomings.

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    -
    - test if mix blend mode works in sepia, and invert in night mode - -
    The image above should blend in sepia mode and inverted in night mode.
    -
    -

    There now is your insular city of the Manhattoes, belted round by wharves as Indian isles by coral reefs—commerce surrounds it with her surf. Right and left, the streets take you waterward. Its extreme downtown is the battery, where that noble mole is washed by waves, and cooled by breezes, which a few hours previous were out of sight of land. Look at the crowds of water-gazers there.

    -

    http://www.averyveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryverylongurl.com

    -

    Circumambulate the city of a dreamy Sabbath afternoon. Go from Corlears Hook to Coenties Slip, and from thence, by Whitehall, northward. What do you see?—Posted like silent sentinels all around the town, stand thousands upon thousands of mortal men fixed in ocean reveries. Some leaning against the spiles; some seated upon the pier-heads; some looking over the bulwarks of ships from China; some high aloft in the rigging, as if striving to get a still better seaward peep. But these are all landsmen; of week days pent up in lath and plaster—tied to counters, nailed to benches, clinched to desks. How then is this? Are the green fields gone? What do they here?

    -

    Rindfleischetikettierungsüberwachungsaufgabenübertragungsgesetz

    -

    But look! here come more crowds, pacing straight for the water, and seemingly bound for a dive. Strange! Nothing will content them but the extremest limit of the land; loitering under the shady lee of yonder warehouses will not suffice. No. They must get just as nigh the water as they possibly can without falling in. And there they stand—miles of them—leagues. Inlanders all, they come from lanes and alleys, streets and avenues—north, east, south, and west. Yet here they all unite. Tell me, does the magnetic virtue of the needles of the compasses of all those ships attract them thither?

    Once more. Say you are in the country; in some high land of lakes. Take almost any path you please, and ten to one it carries you down in a dale, and leaves you there by a pool in the stream. There is magic in it. Let the most absent-minded of men be plunged in his deepest reveries—stand that man on his legs, set his feet a-going, and he will infallibly lead you to water, if water there be in all that region. Should you ever be athirst in the great American desert, try this experiment, if your caravan happen to be supplied with a metaphysical professor. Yes, as every one knows, meditation and water are wedded for ever.

    @@ -101,7 +65,7 @@

    Rindfleischetikettierungsüberwachungsaufgabenübertragungsgesetz

    Again, I always go to sea as a sailor, because they make a point of paying me for my trouble, whereas they never pay passengers a single penny that I ever heard of. On the contrary, passengers themselves must pay. And there is all the difference in the world between paying and being paid. The act of paying is perhaps the most uncomfortable infliction that the two orchard thieves entailed upon us. But being paid,—what will compare with it? The urbane activity with which a man receives money is really marvellous, considering that we so earnestly believe money to be the root of all earthly ills, and that on no account can a monied man enter heaven. Ah! how cheerfully we consign ourselves to perdition!

    - test if safeguards in portrait page + 2 columns (iPad/Desktop-like) + test if safeguards in portrait page + 3 columns (iPad/Desktop-like)

    Finally, I always go to sea as a sailor, because of the wholesome exercise and pure air of the fore-castle deck. For as in this world, head winds are far more prevalent than winds from astern (that is, if you never violate the Pythagorean maxim), so for the most part the Commodore on the quarter-deck gets his atmosphere at second hand from the sailors on the forecastle. He thinks he breathes it first; but not so. In much the same way do the commonalty lead their leaders in many other things, at the same time that the leaders little suspect it. But wherefore it was that after having repeatedly smelt the sea as a merchant sailor, I should now take it into my head to go on a whaling voyage; this the invisible police officer of the Fates, who has the constant surveillance of me, and secretly dogs me, and influences me in some unaccountable way—he can better answer than any one else. And, doubtless, my going on this whaling voyage, formed part of the grand programme of Providence that was drawn up a long time ago. It came in as a sort of brief interlude and solo between more extensive performances. I take it that this part of the bill must have run something like this:

    diff --git a/tests/darken-filter.html b/tests/darken-filter.html new file mode 100644 index 00000000..c1ac01ff --- /dev/null +++ b/tests/darken-filter.html @@ -0,0 +1,24 @@ + + + + Test + + + + + + + +

    CHAPTER 1. Loomings.

    + +

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    + +
    + test if darken filter works + +
    The image above should be darkened and have a grey background.
    +
    + +

    There now is your insular city of the Manhattoes, belted round by wharves as Indian isles by coral reefs—commerce surrounds it with her surf. Right and left, the streets take you waterward. Its extreme downtown is the battery, where that noble mole is washed by waves, and cooled by breezes, which a few hours previous were out of sight of land. Look at the crowds of water-gazers there.

    + + \ No newline at end of file diff --git a/tests/day.html b/tests/default-colors.html similarity index 99% rename from tests/day.html rename to tests/default-colors.html index d2b201cc..0fcef269 100644 --- a/tests/day.html +++ b/tests/default-colors.html @@ -40,9 +40,9 @@

    CHAPTER 1. Loomings.

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    - test if mix blend mode works in sepia, and invert in night mode + test if gaiji work -
    The image above should blend in sepia mode and inverted in night mode.
    +
    The image above can be used to test gaiji.

    There now is your insular city of the Manhattoes, belted round by wharves as Indian isles by coral reefs—commerce surrounds it with her surf. Right and left, the streets take you waterward. Its extreme downtown is the battery, where that noble mole is washed by waves, and cooled by breezes, which a few hours previous were out of sight of land. Look at the crowds of water-gazers there.

    diff --git a/tests/night.html b/tests/default-custom-colors.html similarity index 84% rename from tests/night.html rename to tests/default-custom-colors.html index 577b338e..d3551d69 100644 --- a/tests/night.html +++ b/tests/default-custom-colors.html @@ -1,5 +1,5 @@ - + Test @@ -40,20 +40,30 @@

    CHAPTER 1. Loomings.

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    - test if mix blend mode works in sepia, and invert in night mode + test if gaiji work -
    The image above should blend in sepia mode and inverted in night mode.
    +
    The image above can be used to test gaiji.

    There now is your insular city of the Manhattoes, belted round by wharves as Indian isles by coral reefs—commerce surrounds it with her surf. Right and left, the streets take you waterward. Its extreme downtown is the battery, where that noble mole is washed by waves, and cooled by breezes, which a few hours previous were out of sight of land. Look at the crowds of water-gazers there.

    -

    http://www.averyveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryverylongurl.com

    +

    http://www.averyveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryverylongurl.com

    Circumambulate the city of a dreamy Sabbath afternoon. Go from Corlears Hook to Coenties Slip, and from thence, by Whitehall, northward. What do you see?—Posted like silent sentinels all around the town, stand thousands upon thousands of mortal men fixed in ocean reveries. Some leaning against the spiles; some seated upon the pier-heads; some looking over the bulwarks of ships from China; some high aloft in the rigging, as if striving to get a still better seaward peep. But these are all landsmen; of week days pent up in lath and plaster—tied to counters, nailed to benches, clinched to desks. How then is this? Are the green fields gone? What do they here?

    +
    + This is an aside. +
    +

    Rindfleischetikettierungsüberwachungsaufgabenübertragungsgesetz

    -

    But look! here come more crowds, pacing straight for the water, and seemingly bound for a dive. Strange! Nothing will content them but the extremest limit of the land; loitering under the shady lee of yonder warehouses will not suffice. No. They must get just as nigh the water as they possibly can without falling in. And there they stand—miles of them—leagues. Inlanders all, they come from lanes and alleys, streets and avenues—north, east, south, and west. Yet here they all unite. Tell me, does the magnetic virtue of the needles of the compasses of all those ships attract them thither?

    +

    But look! here come more crowds, pacing straight for the water, and seemingly bound for a dive. Strange! Nothing will content them but the extremest limit of the land; loitering under the shady lee of yonder warehouses will not suffice. No. They must get just as nigh the water as they possibly can without falling in. And there they stand—miles of them—leagues. Inlanders all, they come from lanes and alleys, streets and avenues—north, east, south, and west. Yet here they all unite. Tell me, does the magnetic virtue of the needles of the compasses of all those ships attract them thither? 日本語

    + +

    Once more. Say you are in the country; in some high land of lakes. Take almost any path you please, and ten to one it carries you down in a dale, and leaves you there by a pool in the stream. There is magic in it. Let the most absent-minded of men be plunged in his deepest reveries—stand that man on his legs, set his feet a-going, and he will infallibly lead you to water, if water there be in all that region. Should you ever be athirst in the great American desert, try this experiment, if your caravan happen to be supplied with a metaphysical professor. Yes, as every one knows, meditation and water are wedded for ever.

    @@ -61,7 +71,11 @@

    Rindfleischetikettierungsüberwachungsaufgabenübertragungsgesetz

    test if safeguards in landscape + 1 column (iPhone-like) -

    But here is an artist. He desires to paint you the dreamiest, shadiest, quietest, most enchanting bit of romantic landscape in all the valley of the Saco. What is the chief element he employs? There stand his trees, each with a hollow trunk, as if a hermit and a crucifix were within; and here sleeps his meadow, and there sleep his cattle; and up from yonder cottage goes a sleepy smoke. Deep into distant woodlands winds a mazy way, reaching to overlapping spurs of mountains bathed in their hill-side blue. But though the picture lies thus tranced, and though this pine-tree shakes down its sighs like leaves upon this shepherd’s head, yet all were vain, unless the shepherd’s eye were fixed upon the magic stream before him. Go visit the Prairies in June, when for scores on scores of miles you wade knee-deep among Tiger-lilies—what is the one charm wanting?—Water—there is not a drop of water there! Were Niagara but a cataract of sand, would you travel your thousand miles to see it? Why did the poor poet of Tennessee, upon suddenly receiving two handfuls of silver, deliberate whether to buy him a coat, which he sadly needed, or invest his money in a pedestrian trip to Rockaway Beach? Why is almost every robust healthy boy with a robust healthy soul in him, at some time or other crazy to go to sea? Why upon your first voyage as a passenger, did you yourself feel such a mystical vibration, when first told that you and your ship were now out of sight of land? Why did the old Persians hold the sea holy? Why did the Greeks give it a separate deity, and own brother of Jove? Surely all this is not without meaning. And still deeper the meaning of that story of Narcissus, who because he could not grasp the tormenting, mild image he saw in the fountain, plunged into it and was drowned. But that same image, we ourselves see in all rivers and oceans. It is the image of the ungraspable phantom of life; and this is the key to it all.

    +
    +
    Artist
    + +
    He desires to paint you the dreamiest, shadiest, quietest, most enchanting bit of romantic landscape in all the valley of the Saco. What is the chief element he employs? There stand his trees, each with a hollow trunk, as if a hermit and a crucifix were within; and here sleeps his meadow, and there sleep his cattle; and up from yonder cottage goes a sleepy smoke. Deep into distant woodlands winds a mazy way, reaching to overlapping spurs of mountains bathed in their hill-side blue. But though the picture lies thus tranced, and though this pine-tree shakes down its sighs like leaves upon this shepherd’s head, yet all were vain, unless the shepherd’s eye were fixed upon the magic stream before him. Go visit the Prairies in June, when for scores on scores of miles you wade knee-deep among Tiger-lilies—what is the one charm wanting?—Water—there is not a drop of water there! Were Niagara but a cataract of sand, would you travel your thousand miles to see it? Why did the poor poet of Tennessee, upon suddenly receiving two handfuls of silver, deliberate whether to buy him a coat, which he sadly needed, or invest his money in a pedestrian trip to Rockaway Beach? Why is almost every robust healthy boy with a robust healthy soul in him, at some time or other crazy to go to sea? Why upon your first voyage as a passenger, did you yourself feel such a mystical vibration, when first told that you and your ship were now out of sight of land? Why did the old Persians hold the sea holy? Why did the Greeks give it a separate deity, and own brother of Jove? Surely all this is not without meaning. And still deeper the meaning of that story of Narcissus, who because he could not grasp the tormenting, mild image he saw in the fountain, plunged into it and was drowned. But that same image, we ourselves see in all rivers and oceans. It is the image of the ungraspable phantom of life; and this is the key to it all.
    +

    Now, when I say that I am in the habit of going to sea whenever I begin to grow hazy about the eyes, and begin to be over conscious of my lungs, I do not mean to have it inferred that I ever go to sea as a passenger. For to go as a passenger you must needs have a purse, and a purse is but a rag unless you have something in it. Besides, passengers get sea-sick—grow quarrelsome—don’t sleep of nights—do not enjoy themselves much, as a general thing;—no, I never go as a passenger; nor, though I am something of a salt, do I ever go to sea as a Commodore, or a Captain, or a Cook. I abandon the glory and distinction of such offices to those who like them. For my part, I abominate all honourable respectable toils, trials, and tribulations of every kind whatsoever. It is quite as much as I can do to take care of myself, without taking care of ships, barques, brigs, schooners, and what not. And as for going as cook,—though I confess there is considerable glory in that, a cook being a sort of officer on ship-board—yet, somehow, I never fancied broiling fowls;—though once broiled, judiciously buttered, and judgmatically salted and peppered, there is no one who will speak more respectfully, not to say reverentially, of a broiled fowl than I will. It is out of the idolatrous dotings of the old Egyptians upon broiled ibis and roasted river horse, that you see the mummies of those creatures in their huge bake-houses the pyramids.

    @@ -69,27 +83,27 @@

    Rindfleischetikettierungsüberwachungsaufgabenübertragungsgesetz

    Test table with borders - Header 1 - Header 2 - Header 3 - Header 4 - Header 5 + Header 1 + Header 2 + Header 3 + Header 4 + Header 5 - Table data 1 - Table data 2 - Table data 3 - Table data 4 - Table data 5 + Table data 1 + Table data 2 + Table data 3 + Table data 4 + Table data 5 - Table data 1 - Table data 2 - Table data 3 - Table data 4 - Table data 5 + Table data 1 + Table data 2 + Table data 3 + Table data 4 + Table data 5 diff --git a/tests/font-family.html b/tests/font-family.html index 0bced8e5..2fc077d9 100644 --- a/tests/font-family.html +++ b/tests/font-family.html @@ -1,5 +1,5 @@ - + Test @@ -14,9 +14,9 @@

    CHAPTER 1. Loomings.

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    - test if mix blend mode works in sepia, and invert in night mode + test if gaiji work -
    The image above should blend in sepia mode and inverted in night mode.
    +
    The image above can be used to test gaiji.

    There now is your insular city of the Manhattoes, belted round by wharves as Indian isles by coral reefs—commerce surrounds it with her surf. Right and left, the streets take you waterward. Its extreme downtown is the battery, where that noble mole is washed by waves, and cooled by breezes, which a few hours previous were out of sight of land. Look at the crowds of water-gazers there.

    diff --git a/tests/font-optical-sizing.html b/tests/font-optical-sizing.html new file mode 100644 index 00000000..d6d071a3 --- /dev/null +++ b/tests/font-optical-sizing.html @@ -0,0 +1,25 @@ + + + + Test + + + + + + + + +
    +

    CHAPTER 1. Loomings. (setting off)

    + +

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    +
    + +
    +

    CHAPTER 1. Loomings. (setting on)

    + +

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    +
    + + \ No newline at end of file diff --git a/tests/font-size-deprecated.html b/tests/font-size-deprecated.html new file mode 100644 index 00000000..baa372bb --- /dev/null +++ b/tests/font-size-deprecated.html @@ -0,0 +1,51 @@ + + + + Test + + + + + + + +

    Heading 1

    + +

    Text. Smaller text. Text followed by sup.[1]

    + +

    Heading 2

    + + + +

    Heading 3

    + +
    + This is an aside. +
    + +

    Heading 4

    + +
    +
    Artist
    + +
    He desires to paint you the dreamiest, shadiest, quietest, most enchanting bit of romantic landscape in all the valley of the Saco. What is the chief element he employs? There stand his trees, each with a hollow trunk, as if a hermit and a crucifix were within; and here sleeps his meadow, and there sleep his cattle; and up from yonder cottage goes a sleepy smoke.
    +
    + +
    Heading 5
    + +
    h1 {
    +  font-family: sans-serif;
    +  font-size: 2em;
    +  margin: 1.5em 0;
    +  text-align: center;
    +}
    + +
    Heading 6
    + +

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    + + \ No newline at end of file diff --git a/tests/font-size-normalize.html b/tests/font-size-normalize.html new file mode 100644 index 00000000..cac84062 --- /dev/null +++ b/tests/font-size-normalize.html @@ -0,0 +1,55 @@ + + + + Test + + + + + + + + +

    Heading 1

    + +

    Text. Smaller text. Text followed by sup.[1]

    + +

    Heading 2

    + + + +

    Heading 3

    + +
    + This is an aside. +
    + +

    Heading 4

    + +
    +
    Artist
    + +
    He desires to paint you the dreamiest, shadiest, quietest, most enchanting bit of romantic landscape in all the valley of the Saco. What is the chief element he employs? There stand his trees, each with a hollow trunk, as if a hermit and a crucifix were within; and here sleeps his meadow, and there sleep his cattle; and up from yonder cottage goes a sleepy smoke.
    +
    + +
    Heading 5
    + +
    h1 {
    +  font-family: sans-serif;
    +  font-size: 2em;
    +  margin: 1.5em 0;
    +  text-align: center;
    +}
    + +
    Heading 6
    + +

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    + + \ No newline at end of file diff --git a/tests/font-size.html b/tests/font-size.html index a31086db..c20525fa 100644 --- a/tests/font-size.html +++ b/tests/font-size.html @@ -1,5 +1,5 @@ - + Test diff --git a/tests/font-weight.html b/tests/font-weight.html new file mode 100644 index 00000000..c079c9f0 --- /dev/null +++ b/tests/font-weight.html @@ -0,0 +1,25 @@ + + + + Test + + + + + + + + +
    +

    CHAPTER 1. Loomings. (setting off)

    + +

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    +
    + +
    +

    CHAPTER 1. Loomings. (setting on)

    + +

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    +
    + + \ No newline at end of file diff --git a/tests/font-width-keyword.html b/tests/font-width-keyword.html new file mode 100644 index 00000000..1565dc24 --- /dev/null +++ b/tests/font-width-keyword.html @@ -0,0 +1,25 @@ + + + + Test + + + + + + + + +
    +

    CHAPTER 1. Loomings. (setting off)

    + +

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    +
    + +
    +

    CHAPTER 1. Loomings. (setting on)

    + +

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    +
    + + \ No newline at end of file diff --git a/tests/font-width-percentage.html b/tests/font-width-percentage.html new file mode 100644 index 00000000..989b1029 --- /dev/null +++ b/tests/font-width-percentage.html @@ -0,0 +1,25 @@ + + + + Test + + + + + + + + +
    +

    CHAPTER 1. Loomings. (setting off)

    + +

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    +
    + +
    +

    CHAPTER 1. Loomings. (setting on)

    + +

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    +
    + + \ No newline at end of file diff --git a/tests/hyphens.html b/tests/hyphens.html index 4d2e0627..4e4ef977 100644 --- a/tests/hyphens.html +++ b/tests/hyphens.html @@ -1,5 +1,5 @@ - + Test @@ -24,11 +24,11 @@

    CHAPTER 1. Loomings.

    in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    -
    - test if mix blend mode works in sepia, and invert in night mode - -
    The image above should blend in sepia mode and inverted in night mode.
    -
    +
    + test if gaiji work + +
    The image above can be used to test gaiji.
    +

    There now is your insular city of the Manhattoes, belted round by wharves as Indian isles by coral reefs—commerce surrounds it with her surf. Right and left, the streets take you waterward. Its extreme downtown is the battery, where that noble diff --git a/tests/invert-filter.html b/tests/invert-filter.html new file mode 100644 index 00000000..1f9b0fd2 --- /dev/null +++ b/tests/invert-filter.html @@ -0,0 +1,24 @@ + + + + Test + + + + + + + +

    CHAPTER 1. Loomings.

    + +

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    + +
    + test if invert works with a custom percentage + +
    The image above should be inverted but not totally (70%).
    +
    + +

    There now is your insular city of the Manhattoes, belted round by wharves as Indian isles by coral reefs—commerce surrounds it with her surf. Right and left, the streets take you waterward. Its extreme downtown is the battery, where that noble mole is washed by waves, and cooled by breezes, which a few hours previous were out of sight of land. Look at the crowds of water-gazers there.

    + + \ No newline at end of file diff --git a/tests/letter-spacing-cjk.html b/tests/letter-spacing-cjk.html index 49d5c6f5..684179e5 100644 --- a/tests/letter-spacing-cjk.html +++ b/tests/letter-spacing-cjk.html @@ -1,5 +1,5 @@ - + Test diff --git a/tests/letter-spacing.html b/tests/letter-spacing.html index 7336878a..b6c41858 100644 --- a/tests/letter-spacing.html +++ b/tests/letter-spacing.html @@ -1,5 +1,5 @@ - + Test diff --git a/tests/line-height.html b/tests/line-height.html index cfab0259..6fb64d38 100644 --- a/tests/line-height.html +++ b/tests/line-height.html @@ -1,5 +1,5 @@ - + Test diff --git a/tests/margins.html b/tests/line-length.html similarity index 98% rename from tests/margins.html rename to tests/line-length.html index 96f970be..bfd2f9a3 100644 --- a/tests/margins.html +++ b/tests/line-length.html @@ -1,5 +1,5 @@ - + Test diff --git a/tests/no-ruby.html b/tests/no-ruby.html index 1a844f0a..e87ee5b1 100644 --- a/tests/no-ruby.html +++ b/tests/no-ruby.html @@ -1,5 +1,5 @@ - + Test diff --git a/tests/para-spacing-vertical.html b/tests/para-spacing-vertical.html index 2b66c975..571a8fac 100644 --- a/tests/para-spacing-vertical.html +++ b/tests/para-spacing-vertical.html @@ -1,5 +1,5 @@ - + Test diff --git a/tests/para-spacing.html b/tests/para-spacing.html index 2655ec3e..bd280289 100644 --- a/tests/para-spacing.html +++ b/tests/para-spacing.html @@ -1,5 +1,5 @@ - + Test diff --git a/tests/scroll-padding.html b/tests/scroll-padding.html new file mode 100644 index 00000000..f297fbe2 --- /dev/null +++ b/tests/scroll-padding.html @@ -0,0 +1,38 @@ + + + + Test + + + + + + + +

    CHAPTER 1. Loomings.

    + +

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    + +
    + test if gaiji work + +
    The image above can be used to test gaiji.
    +
    + +

    There now is your insular city of the Manhattoes, belted round by wharves as Indian isles by coral reefs—commerce surrounds it with her surf. Right and left, the streets take you waterward. Its extreme downtown is the battery, where that noble mole is washed by waves, and cooled by breezes, which a few hours previous were out of sight of land. Look at the crowds of water-gazers there.

    + +

    http://www.averyveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryverylongurl.com

    + +

    Circumambulate the city of a dreamy Sabbath afternoon. Go from Corlears Hook to Coenties Slip, and from thence, by Whitehall, northward. What do you see?—Posted like silent sentinels all around the town, stand thousands upon thousands of mortal men fixed in ocean reveries. Some leaning against the spiles; some seated upon the pier-heads; some looking over the bulwarks of ships from China; some high aloft in the rigging, as if striving to get a still better seaward peep. But these are all landsmen; of week days pent up in lath and plaster—tied to counters, nailed to benches, clinched to desks. How then is this? Are the green fields gone? What do they here?

    + +

    Rindfleischetikettierungsüberwachungsaufgabenübertragungsgesetz

    + +

    But look! here come more crowds, pacing straight for the water, and seemingly bound for a dive. Strange! Nothing will content them but the extremest limit of the land; loitering under the shady lee of yonder warehouses will not suffice. No. They must get just as nigh the water as they possibly can without falling in. And there they stand—miles of them—leagues. Inlanders all, they come from lanes and alleys, streets and avenues—north, east, south, and west. Yet here they all unite. Tell me, does the magnetic virtue of the needles of the compasses of all those ships attract them thither?

    + +

    Once more. Say you are in the country; in some high land of lakes. Take almost any path you please, and ten to one it carries you down in a dale, and leaves you there by a pool in the stream. There is magic in it. Let the most absent-minded of men be plunged in his deepest reveries—stand that man on his legs, set his feet a-going, and he will infallibly lead you to water, if water there be in all that region. Should you ever be athirst in the great American desert, try this experiment, if your caravan happen to be supplied with a metaphysical professor. Yes, as every one knows, meditation and water are wedded for ever.

    + +
    + test if safeguards in landscape + 1 column (iPhone-like) +
    + + \ No newline at end of file diff --git a/tests/scroll.html b/tests/scroll.html index 1fbbdd0d..051d783e 100644 --- a/tests/scroll.html +++ b/tests/scroll.html @@ -14,7 +14,9 @@

    CHAPTER 1. Loomings.

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    - test if mix blend mode works in sepia, and invert in night mode + test if gaiji work + +
    The image above can be used to test gaiji.

    There now is your insular city of the Manhattoes, belted round by wharves as Indian isles by coral reefs—commerce surrounds it with her surf. Right and left, the streets take you waterward. Its extreme downtown is the battery, where that noble mole is washed by waves, and cooled by breezes, which a few hours previous were out of sight of land. Look at the crowds of water-gazers there.

    diff --git a/tests/text-align.html b/tests/text-align.html index e1c76d5b..4a3b68bd 100644 --- a/tests/text-align.html +++ b/tests/text-align.html @@ -1,5 +1,5 @@ - + Test @@ -14,7 +14,7 @@

    CHAPTER 1. Loomings.

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    - test if mix blend mode works in sepia, and invert in night mode + test if gaiji work

    The caption should be centered.

    diff --git a/tests/theming.html b/tests/theming.html new file mode 100644 index 00000000..1535bf2e --- /dev/null +++ b/tests/theming.html @@ -0,0 +1,99 @@ + + + + Test + + + + + + + +

    CHAPTER 1. Loomings.

    + +

    Call me Ishmael. Some years ago—never mind how long precisely—having little or no money in my purse, and nothing particular to interest me on shore, I thought I would sail about a little and see the watery part of the world. It is a way I have of driving off the spleen and regulating the circulation. Whenever I find myself growing grim about the mouth; whenever it is a damp, drizzly November in my soul; whenever I find myself involuntarily pausing before coffin warehouses, and bringing up the rear of every funeral I meet; and especially whenever my hypos get such an upper hand of me, that it requires a strong moral principle to prevent me from deliberately stepping into the street, and methodically knocking people’s hats off—then, I account it high time to get to sea as soon as I can. This is my substitute for pistol and ball. With a philosophical flourish Cato throws himself upon his sword; I quietly take to the ship. There is nothing surprising in this. If they but knew it, almost all men in their degree, some time or other, cherish very nearly the same feelings towards the ocean with me.

    + +

    There now is your insular city of the Manhattoes, belted round by wharves as Indian isles by coral reefs—commerce surrounds it with her surf. Right and left, the streets take you waterward. Its extreme downtown is the battery, where that noble mole is washed by waves, and cooled by breezes, which a few hours previous were out of sight of land. Look at the crowds of water-gazers there.

    + +

    http://www.averyveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryveryverylongurl.com

    + +

    Circumambulate the city of a dreamy Sabbath afternoon. Go from Corlears Hook to Coenties Slip, and from thence, by Whitehall, northward. What do you see?—Posted like silent sentinels all around the town, stand thousands upon thousands of mortal men fixed in ocean reveries. Some leaning against the spiles; some seated upon the pier-heads; some looking over the bulwarks of ships from China; some high aloft in the rigging, as if striving to get a still better seaward peep. But these are all landsmen; of week days pent up in lath and plaster—tied to counters, nailed to benches, clinched to desks. How then is this? Are the green fields gone? What do they here?

    + +
    + This is an aside. +
    + +

    Rindfleischetikettierungsüberwachungsaufgabenübertragungsgesetz

    + +

    But look! here come more crowds, pacing straight for the water, and seemingly bound for a dive. Strange! Nothing will content them but the extremest limit of the land; loitering under the shady lee of yonder warehouses will not suffice. No. They must get just as nigh the water as they possibly can without falling in. And there they stand—miles of them—leagues. Inlanders all, they come from lanes and alleys, streets and avenues—north, east, south, and west. Yet here they all unite. Tell me, does the magnetic virtue of the needles of the compasses of all those ships attract them thither? 日本語

    + + + +

    Once more. Say you are in the country; in some high land of lakes. Take almost any path you please, and ten to one it carries you down in a dale, and leaves you there by a pool in the stream. There is magic in it. Let the most absent-minded of men be plunged in his deepest reveries—stand that man on his legs, set his feet a-going, and he will infallibly lead you to water, if water there be in all that region. Should you ever be athirst in the great American desert, try this experiment, if your caravan happen to be supplied with a metaphysical professor. Yes, as every one knows, meditation and water are wedded for ever.

    + +
    + test if safeguards in landscape + 1 column (iPhone-like) +
    + +
    +
    Artist
    + +
    He desires to paint you the dreamiest, shadiest, quietest, most enchanting bit of romantic landscape in all the valley of the Saco. What is the chief element he employs? There stand his trees, each with a hollow trunk, as if a hermit and a crucifix were within; and here sleeps his meadow, and there sleep his cattle; and up from yonder cottage goes a sleepy smoke. Deep into distant woodlands winds a mazy way, reaching to overlapping spurs of mountains bathed in their hill-side blue. But though the picture lies thus tranced, and though this pine-tree shakes down its sighs like leaves upon this shepherd’s head, yet all were vain, unless the shepherd’s eye were fixed upon the magic stream before him. Go visit the Prairies in June, when for scores on scores of miles you wade knee-deep among Tiger-lilies—what is the one charm wanting?—Water—there is not a drop of water there! Were Niagara but a cataract of sand, would you travel your thousand miles to see it? Why did the poor poet of Tennessee, upon suddenly receiving two handfuls of silver, deliberate whether to buy him a coat, which he sadly needed, or invest his money in a pedestrian trip to Rockaway Beach? Why is almost every robust healthy boy with a robust healthy soul in him, at some time or other crazy to go to sea? Why upon your first voyage as a passenger, did you yourself feel such a mystical vibration, when first told that you and your ship were now out of sight of land? Why did the old Persians hold the sea holy? Why did the Greeks give it a separate deity, and own brother of Jove? Surely all this is not without meaning. And still deeper the meaning of that story of Narcissus, who because he could not grasp the tormenting, mild image he saw in the fountain, plunged into it and was drowned. But that same image, we ourselves see in all rivers and oceans. It is the image of the ungraspable phantom of life; and this is the key to it all.
    +
    + +

    Now, when I say that I am in the habit of going to sea whenever I begin to grow hazy about the eyes, and begin to be over conscious of my lungs, I do not mean to have it inferred that I ever go to sea as a passenger. For to go as a passenger you must needs have a purse, and a purse is but a rag unless you have something in it. Besides, passengers get sea-sick—grow quarrelsome—don’t sleep of nights—do not enjoy themselves much, as a general thing;—no, I never go as a passenger; nor, though I am something of a salt, do I ever go to sea as a Commodore, or a Captain, or a Cook. I abandon the glory and distinction of such offices to those who like them. For my part, I abominate all honourable respectable toils, trials, and tribulations of every kind whatsoever. It is quite as much as I can do to take care of myself, without taking care of ships, barques, brigs, schooners, and what not. And as for going as cook,—though I confess there is considerable glory in that, a cook being a sort of officer on ship-board—yet, somehow, I never fancied broiling fowls;—though once broiled, judiciously buttered, and judgmatically salted and peppered, there is no one who will speak more respectfully, not to say reverentially, of a broiled fowl than I will. It is out of the idolatrous dotings of the old Egyptians upon broiled ibis and roasted river horse, that you see the mummies of those creatures in their huge bake-houses the pyramids.

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Test table with borders
    Header 1Header 2Header 3Header 4Header 5
    Table data 1Table data 2Table data 3Table data 4Table data 5
    Table data 1Table data 2Table data 3Table data 4Table data 5
    + +

    No, when I go to sea, I go as a simple sailor, right before the mast, plumb down into the forecastle, aloft there to the royal mast-head. True, they rather order me about some, and make me jump from spar to spar, like a grasshopper in a May meadow. And at first, this sort of thing is unpleasant enough. It touches one’s sense of honour, particularly if you come of an old established family in the land, the Van Rensselaers, or Randolphs, or Hardicanutes. And more than all, if just previous to putting your hand into the tar-pot, you have been lording it as a country schoolmaster, making the tallest boys stand in awe of you. The transition is a keen one, I assure you, from a schoolmaster to a sailor, and requires a strong decoction of Seneca and the Stoics to enable you to grin and bear it. But even this wears off in time.

    + +

    What of it, if some old hunks of a sea-captain orders me to get a broom and sweep down the decks? What does that indignity amount to, weighed, I mean, in the scales of the New Testament? Do you think the archangel Gabriel thinks anything the less of me, because I promptly and respectfully obey that old hunks in that particular instance? Who ain’t a slave? Tell me that. Well, then, however the old sea-captains may order me about—however they may thump and punch me about, I have the satisfaction of knowing that it is all right; that everybody else is one way or other served in much the same way—either in a physical or metaphysical point of view, that is; and so the universal thump is passed round, and all hands should rub each other’s shoulder-blades, and be content.

    + +

    Again, I always go to sea as a sailor, because they make a point of paying me for my trouble, whereas they never pay passengers a single penny that I ever heard of. On the contrary, passengers themselves must pay. And there is all the difference in the world between paying and being paid. The act of paying is perhaps the most uncomfortable infliction that the two orchard thieves entailed upon us. But being paid,—what will compare with it? The urbane activity with which a man receives money is really marvellous, considering that we so earnestly believe money to be the root of all earthly ills, and that on no account can a monied man enter heaven. Ah! how cheerfully we consign ourselves to perdition!

    + +
    + test if safeguards in portrait page + 2 columns (iPad/Desktop-like) +
    + +

    Finally, I always go to sea as a sailor, because of the wholesome exercise and pure air of the fore-castle deck. For as in this world, head winds are far more prevalent than winds from astern (that is, if you never violate the Pythagorean maxim), so for the most part the Commodore on the quarter-deck gets his atmosphere at second hand from the sailors on the forecastle. He thinks he breathes it first; but not so. In much the same way do the commonalty lead their leaders in many other things, at the same time that the leaders little suspect it. But wherefore it was that after having repeatedly smelt the sea as a merchant sailor, I should now take it into my head to go on a whaling voyage; this the invisible police officer of the Fates, who has the constant surveillance of me, and secretly dogs me, and influences me in some unaccountable way—he can better answer than any one else. And, doubtless, my going on this whaling voyage, formed part of the grand programme of Providence that was drawn up a long time ago. It came in as a sort of brief interlude and solo between more extensive performances. I take it that this part of the bill must have run something like this:

    + +

    “Grand Contested Election for the Presidency of the United States. “WHALING VOYAGE BY ONE ISHMAEL. “BLOODY BATTLE IN AFFGHANISTAN.”

    + +

    Though I cannot tell why it was exactly that those stage managers, the Fates, put me down for this shabby part of a whaling voyage, when others were set down for magnificent parts in high tragedies, and short and easy parts in genteel comedies, and jolly parts in farces—though I cannot tell why this was exactly; yet, now that I recall all the circumstances, I think I can see a little into the springs and motives which being cunningly presented to me under various disguises, induced me to set about performing the part I did, besides cajoling me into the delusion that it was a choice resulting from my own unbiased freewill and discriminating judgment.

    + +

    Chief among these motives was the overwhelming idea of the great whale himself. Such a portentous and mysterious monster roused all my curiosity. Then the wild and distant seas where he rolled his island bulk; the undeliverable, nameless perils of the whale; these, with all the attending marvels of a thousand Patagonian sights and sounds, helped to sway me to my wish. With other men, perhaps, such things would not have been inducements; but as for me, I am tormented with an everlasting itch for things remote. I love to sail forbidden seas, and land on barbarous coasts. Not ignoring what is good, I am quick to perceive a horror, and could still be social with it—would they let me—since it is but well to be on friendly terms with all the inmates of the place one lodges in.

    + +

    By reason of these things, then, the whaling voyage was welcome; the great flood-gates of the wonder-world swung open, and in the wild conceits that swayed me to my purpose, two and two there floated into my inmost soul, endless processions of the whale, and, mid most of them all, one grand hooded phantom, like a snow hill in the air.

    + + \ No newline at end of file diff --git a/tests/type-scale.html b/tests/type-scale.html index 76e75cff..1ae15cf4 100644 --- a/tests/type-scale.html +++ b/tests/type-scale.html @@ -1,5 +1,5 @@ - + Test diff --git a/tests/word-spacing.html b/tests/word-spacing.html index 4919911a..b8a8eadb 100644 --- a/tests/word-spacing.html +++ b/tests/word-spacing.html @@ -1,5 +1,5 @@ - + Test