-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'origin/master' into 185581730-add-points
- Loading branch information
Showing
8 changed files
with
3,695 additions
and
7,510 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import { parse } from "query-string"; | ||
|
||
/** | ||
* This is related to [url-params.ts](../../src/utilities/url-params.ts). | ||
* It is a subset of the parameters in that module so the CMS doesn't need to import | ||
* all of the dependencies used by `url-params.ts` | ||
*/ | ||
export interface QueryParams { | ||
// string, e.g. "sas" for Stretching and Shrinking or "msa" for Moving Straight Ahead | ||
unit?: string; | ||
|
||
// | ||
// CMS options (admin.html) | ||
// | ||
|
||
// change the branch used in clue-curriculum repository default is author | ||
curriculumBranch?: string; | ||
// work with a local checkout of the curriculum instead of github | ||
localCMSBackend?: boolean; | ||
// change the location of the cms-editor.html used by iframe widget to edit | ||
// CLUE documents. | ||
cmsEditorBase?: string; | ||
} | ||
|
||
export const processUrlParams = (): QueryParams => { | ||
const params = parse(location.search); | ||
return { | ||
...params, | ||
// allows use of localCMSBackend without a value | ||
localCMSBackend: (params.localCMSBackend !== undefined), | ||
}; | ||
}; | ||
|
||
export const urlParams = processUrlParams(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"extends": "../tsconfig.json", | ||
"include": ["src/**/*"], | ||
"exclude": ["**/node_modules", "**/.*/"] | ||
} |