Skip to content

Commit e972c89

Browse files
Merge pull request #569 from creativecommons/ux-boost
correct specificity of styles, narrow scope to only `chooser-page` context, update `README.md`
2 parents e60860c + 27e4205 commit e972c89

File tree

2 files changed

+92
-69
lines changed

2 files changed

+92
-69
lines changed

README.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,36 @@ See [`CONTRIBUTING.md`][org-contrib].
4141

4242
## Development
4343

44+
All necessary files to bundle or run the Chooser are located within the `/src` directory.
45+
4446
* `/src/index.html`: relevant HTML markup.
4547
* `/src/style.css`: localized styles, built on top of [Vocabulary][vocabulary].
4648
* `/src/scripts.js`: relevant JavaScript logic.
4749

50+
The Chooser exists bundled within the [`vocabulary-theme`][vocabulary-theme] repository for production purposes. This repository is for isolated development purposes, similar to the setup followed by [`cc-legal-tools-app`][cc-legal-tools-app] + [`cc-legal-tools-data`][cc-legal-tools-data], and [`index-prototype`][index-prototype].
51+
52+
Once changes are implemented here, they need to be updated within the `/chooser` directory within `vocabulary-theme`.
53+
54+
Final production changes are deployed within vocabulary-theme Releases, updated within [`index-dev-env`][index-dev-env], and finally deployed to `index__stage` and then `index__prod` environments; going LIVE at `https://creativecommons.org/choose`.
55+
4856

4957
## Setup
5058
1. open the `src/index.html` file within a browser to view the Chooser.
5159

60+
[cc-legal-tools-app]: https://github.com/creativecommons/cc-legal-tools-app
61+
[cc-legal-tools-data]: https://github.com/creativecommons/cc-legal-tools-data
62+
[index-dev-env]: https://github.com/creativecommons/index-dev-env
63+
[index-prototype]: https://github.com/creativecommons/index-prototype
5264
[vocabulary]: https://github.com/creativecommons/vocabulary
65+
[vocabulary-theme]: https://github.com/creativecommons/vocabulary-theme
66+
67+
68+
## Structure
69+
70+
The initial markup is rendered via the `index.html` file. Visual display is derived from the `style.css` rules.
71+
72+
On initlialization the `scripts.js` functions set the correct fieldsets to default display; based on user provided actions through the stepper fieldsets will display or hide, exposing the relevant pathways to getting a `tool` recommendation. Correct pathways are located within the `rawStatePathRoutes` array. When a correct pathway matches the current `state`, the appropriate `tool` is matched and recommended, if the current state is not a known pathway the `tool` is set to `unknown` until the required input is given.
73+
74+
The main `tool` recommendation content is pull via the appropriate `<template>` markup located within HTML. Additional information for the marking formats is also sourced from these `<template>` elements and the contents of the `Attribution Details` fields.
75+
76+
Marking formats are pulled from a combination of HTML markup and JS string interpolation found within the `scripts.js` file within the `renderMarkingFormats` function.

0 commit comments

Comments
 (0)