├── .nvmrc ├── app ├── sites │ └── claydemo │ │ ├── media │ │ ├── mask.svg │ │ ├── favicon.ico │ │ ├── facebook-square.svg │ │ ├── twitter.svg │ │ └── logo.svg │ │ ├── static │ │ └── robots.txt │ │ ├── bootstrap.yml │ │ ├── config.yml │ │ └── index.js ├── .eslintignore ├── .prettierignore ├── components │ ├── divider │ │ ├── bootstrap.yml │ │ ├── schema.yml │ │ └── template.hbs │ ├── meta-url │ │ ├── bootstrap.yml │ │ ├── template.handlebars │ │ ├── model.js │ │ └── schema.yml │ ├── footer │ │ ├── bootstrap.yaml │ │ ├── template.hbs │ │ └── schema.yaml │ ├── meta-site │ │ ├── bootstrap.yml │ │ ├── schema.yml │ │ └── template.handlebars │ ├── meta-authors │ │ ├── bootstrap.yml │ │ ├── template.handlebars │ │ ├── schema.yml │ │ └── model.js │ ├── meta-image │ │ ├── bootstrap.yml │ │ ├── template.hbs │ │ └── schema.yml │ ├── meta-keywords │ │ ├── bootstrap.yml │ │ ├── schema.yml │ │ ├── template.handlebars │ │ └── model.js │ ├── header │ │ ├── bootstrap.yml │ │ ├── model.js │ │ ├── client.js │ │ ├── schema.yaml │ │ └── template.hbs │ ├── tags │ │ ├── bootstrap.yml │ │ ├── client.js │ │ ├── schema.yaml │ │ ├── model.js │ │ └── template.hbs │ ├── meta-description │ │ ├── bootstrap.yml │ │ ├── template.handlebars │ │ └── schema.yml │ ├── list │ │ ├── bootstrap.yml │ │ ├── template.hbs │ │ ├── model.js │ │ └── schema.yml │ ├── meta-icons │ │ ├── bootstrap.yml │ │ ├── template.handlebars │ │ └── schema.yml │ ├── meta-title │ │ ├── bootstrap.yml │ │ ├── template.handlebars │ │ ├── model.js │ │ └── schema.yml │ ├── paragraph │ │ ├── bootstrap.yml │ │ ├── template.hbs │ │ ├── model.js │ │ └── schema.yml │ ├── subheader │ │ ├── bootstrap.yml │ │ ├── media │ │ │ └── icon-link.svg │ │ ├── template.hbs │ │ ├── model.js │ │ └── schema.yml │ ├── image │ │ ├── bootstrap.yml │ │ ├── media │ │ │ ├── ar-square.svg │ │ │ ├── ar-vertical.svg │ │ │ ├── ar-horizontal.svg │ │ │ ├── ar-deep-vertical.svg │ │ │ ├── size-breakout.svg │ │ │ ├── size-inline.svg │ │ │ └── size-inset.svg │ │ ├── schema.yml │ │ ├── model.js │ │ └── template.hbs │ ├── code-sample │ │ ├── bootstrap.yml │ │ ├── template.hbs │ │ ├── model.js │ │ └── schema.yml │ ├── pull-quote │ │ ├── bootstrap.yml │ │ ├── template.hbs │ │ └── schema.yml │ └── article │ │ ├── media │ │ ├── icon-square.svg │ │ ├── icon-vertical.svg │ │ ├── icon-horizontal.svg │ │ ├── warning.svg │ │ ├── icon-feed-horizontal.svg │ │ ├── icon-feature.svg │ │ ├── icon-special-feature.svg │ │ ├── icon-feed-square.svg │ │ ├── icon-feed-noimg.svg │ │ ├── icon-inline.svg │ │ ├── icon-inset.svg │ │ ├── icon-feed-thumb.svg │ │ └── icon-sponsored-info.svg │ │ ├── bootstrap.yml │ │ ├── template.hbs │ │ ├── model.js │ │ └── schema.yaml ├── .prettierrc ├── styleguides │ ├── claydemo │ │ └── fonts │ │ │ ├── Grotesk-Medium.woff2 │ │ │ ├── Grotesk-SemiBold.woff2 │ │ │ └── GroteskNarrow-SemiBold.woff2 │ └── _default │ │ ├── components │ │ ├── divider.css │ │ ├── paragraph.css │ │ ├── code-sample.css │ │ ├── divider_short.css │ │ ├── tags.css │ │ ├── subheader.css │ │ ├── pull-quote.css │ │ ├── footer.css │ │ ├── header.css │ │ ├── list.css │ │ ├── container-rail.css │ │ ├── image.css │ │ └── article.css │ │ ├── common │ │ └── _vars.css │ │ └── layouts │ │ ├── layout.css │ │ └── layout-simple.css ├── claycli.config.js ├── layouts │ ├── layout-simple │ │ ├── bootstrap.yml │ │ ├── schema.yml │ │ └── template.hbs │ └── layout │ │ ├── schema.yml │ │ └── template.hbs ├── .stylelintrc.yml ├── nodemon.json ├── services │ ├── kiln │ │ ├── index.js │ │ └── plugins │ │ │ └── word-count.js │ ├── startup │ │ ├── amphora-renderers.js │ │ ├── amphora-core.js │ │ └── index.js │ ├── client │ │ ├── buffer.js │ │ ├── db.js │ │ ├── popup.js │ │ └── sharePopup.js │ ├── universal │ │ ├── styles.js │ │ ├── callout.js │ │ ├── article-timestamp.js │ │ ├── helpers.js │ │ ├── byline.js │ │ ├── truncate.js │ │ ├── log.js │ │ ├── format-time.js │ │ ├── word-count.js │ │ ├── sanitize.js │ │ ├── rest.js │ │ └── utils.js │ └── server │ │ ├── buffer.js │ │ ├── publish-url.js │ │ ├── db.js │ │ ├── resolve-media.js │ │ └── publish-utils.js ├── app.js ├── .env.sample ├── package.json └── .eslintrc.js ├── Dockerfile ├── sample_users.yml ├── bootstrap-starter-data ├── _lists.yml ├── _pages.yml ├── _layouts.yml └── _components.yml ├── .github ├── PULL_REQUEST_TEMPLATE.md └── ISSUE_TEMPLATE │ ├── feature_request.md │ └── bug_report.md ├── .dockerignore ├── nginx └── configs │ └── default.conf ├── elasticsearch └── config │ ├── elasticsearch.yml │ └── logging.yml ├── Makefile ├── LICENSE ├── docs └── clay-access-key.md ├── .gitignore ├── .circleci └── config.yml ├── docker-compose.yml └── README.md /.nvmrc: -------------------------------------------------------------------------------- 1 | 12 2 | -------------------------------------------------------------------------------- /app/sites/claydemo/media/mask.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/sites/claydemo/media/favicon.ico: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/.eslintignore: -------------------------------------------------------------------------------- 1 | public/* 2 | node_modules/ 3 | -------------------------------------------------------------------------------- /app/.prettierignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | public 3 | -------------------------------------------------------------------------------- /app/sites/claydemo/static/robots.txt: -------------------------------------------------------------------------------- 1 | User-agent: 2 | Disallow: 3 | -------------------------------------------------------------------------------- /app/components/divider/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | divider: 3 | title: '' 4 | -------------------------------------------------------------------------------- /app/components/meta-url/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | meta-url: 3 | url: '' 4 | -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM node:12 2 | 3 | WORKDIR /usr/local/src/ 4 | COPY app/ ./ 5 | RUN npm i 6 | -------------------------------------------------------------------------------- /app/components/footer/bootstrap.yaml: -------------------------------------------------------------------------------- 1 | _components: 2 | footer: 3 | footerLinks: [] 4 | -------------------------------------------------------------------------------- /app/components/meta-site/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | meta-site: 3 | siteName: '' 4 | -------------------------------------------------------------------------------- /app/components/meta-authors/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | meta-authors: 3 | authors: [] 4 | -------------------------------------------------------------------------------- /app/components/meta-image/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | meta-image: 3 | imageUrl: '' 4 | -------------------------------------------------------------------------------- /app/components/meta-keywords/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | meta-keywords: 3 | tags: [] 4 | -------------------------------------------------------------------------------- /app/components/header/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | header: 3 | componentVariation: header 4 | -------------------------------------------------------------------------------- /app/components/tags/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | tags: 3 | items: [] 4 | normalizedTags: [] 5 | -------------------------------------------------------------------------------- /app/.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "trailingComma": "none", 3 | "singleQuote": true, 4 | "printWidth": 100 5 | } 6 | -------------------------------------------------------------------------------- /app/components/meta-description/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | meta-description: 3 | description: '' 4 | -------------------------------------------------------------------------------- /app/components/list/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | list: 3 | items: [] 4 | sass: '' 5 | listType: '' 6 | -------------------------------------------------------------------------------- /app/components/meta-icons/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | meta-icons: 3 | siteName: '' 4 | favicon: '' 5 | -------------------------------------------------------------------------------- /app/components/meta-title/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | meta-title: 3 | title: '' 4 | kilnTitle: '' 5 | -------------------------------------------------------------------------------- /app/components/paragraph/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | paragraph: 3 | componentVariation: paragraph 4 | text: '' 5 | -------------------------------------------------------------------------------- /app/components/subheader/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | subheader: 3 | text: '' 4 | type: 'h2' 5 | link: '' 6 | -------------------------------------------------------------------------------- /app/components/image/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | image: 3 | imageUrl: '' 4 | imageCaption: '' 5 | imageAlt: '' 6 | -------------------------------------------------------------------------------- /app/components/code-sample/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | code-sample: 3 | code: '' 4 | language: 'javascript' 5 | html: '' 6 | -------------------------------------------------------------------------------- /app/components/pull-quote/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | pull-quote: 3 | quote: '' 4 | hasQuoteMarks: false 5 | attribution: '' 6 | -------------------------------------------------------------------------------- /app/components/paragraph/template.hbs: -------------------------------------------------------------------------------- 1 |
{{{ text }}}
2 | -------------------------------------------------------------------------------- /app/styleguides/claydemo/fonts/Grotesk-Medium.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/clay/clay-starter/HEAD/app/styleguides/claydemo/fonts/Grotesk-Medium.woff2 -------------------------------------------------------------------------------- /app/components/meta-description/template.handlebars: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /app/styleguides/claydemo/fonts/Grotesk-SemiBold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/clay/clay-starter/HEAD/app/styleguides/claydemo/fonts/Grotesk-SemiBold.woff2 -------------------------------------------------------------------------------- /app/components/article/media/icon-square.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/components/article/media/icon-vertical.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/styleguides/claydemo/fonts/GroteskNarrow-SemiBold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/clay/clay-starter/HEAD/app/styleguides/claydemo/fonts/GroteskNarrow-SemiBold.woff2 -------------------------------------------------------------------------------- /app/components/article/media/icon-horizontal.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/components/meta-authors/template.handlebars: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /sample_users.yml: -------------------------------------------------------------------------------- 1 | # Below is a sample user object for an admin user 2 | _users: 3 | - 4 | username: admin 5 | password: clay 6 | provider: local 7 | auth: admin 8 | -------------------------------------------------------------------------------- /app/components/meta-icons/template.handlebars: -------------------------------------------------------------------------------- 1 | 2 | {{! Favicon }} 3 | 4 | -------------------------------------------------------------------------------- /app/sites/claydemo/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | # Required to have a Kiln instance for edit mode 3 | clay-kiln: 4 | instances: 5 | general: 6 | enabled: true 7 | -------------------------------------------------------------------------------- /app/styleguides/_default/components/divider.css: -------------------------------------------------------------------------------- 1 | $divider_color: #767676; 2 | 3 | .divider { 4 | border-top: 1px solid $divider_color; 5 | margin: 0 0 20px; 6 | width: 100%; 7 | } 8 | -------------------------------------------------------------------------------- /app/styleguides/_default/components/paragraph.css: -------------------------------------------------------------------------------- 1 | $black: #000; 2 | $serif-stack: Georgia, serif; 3 | 4 | .paragraph { 5 | color: $black; 6 | font: 18px/1.5 $serif-stack; 7 | margin: 0 0 1em; 8 | } 9 | -------------------------------------------------------------------------------- /app/styleguides/_default/components/code-sample.css: -------------------------------------------------------------------------------- 1 | @import 'prismjs/themes/prism.css'; 2 | 3 | /* To use different theme. All theme css in prismjs/themes/xxxxx */ 4 | /* @import 'prismjs/themes/prism-dark.css'; */ 5 | -------------------------------------------------------------------------------- /app/components/article/media/warning.svg: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /app/claycli.config.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | module.exports = { 4 | babelTargets: { browsers: '> 0.25%, not dead' }, 5 | autoprefixerOptions: { browsers: ['last 2 versions', 'ie >= 9', 'ios >= 7', 'android >= 4.4.2'] } 6 | }; 7 | -------------------------------------------------------------------------------- /app/components/article/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _components: 2 | article: 3 | authors: [] 4 | byline: [] 5 | dateUpdated: false 6 | content: [] 7 | tags: 8 | _ref: /_components/tags 9 | normalizedTags: [] 10 | -------------------------------------------------------------------------------- /bootstrap-starter-data/_lists.yml: -------------------------------------------------------------------------------- 1 | _lists: 2 | new-pages: 3 | - id: articles 4 | title: '1. Articles' 5 | children: 6 | - id: new-standard 7 | title: Article 8 | tags: [] 9 | authors: [] 10 | -------------------------------------------------------------------------------- /app/components/article/media/icon-feed-horizontal.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/components/article/media/icon-feature.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/components/meta-image/template.hbs: -------------------------------------------------------------------------------- 1 | 2 | {{#if imageUrl}} 3 | 4 | 5 | {{/if}} 6 | -------------------------------------------------------------------------------- /app/layouts/layout-simple/bootstrap.yml: -------------------------------------------------------------------------------- 1 | _layouts: 2 | layout-simple: 3 | head: head 4 | headLayout: [] 5 | top: top 6 | header: header 7 | main: main 8 | bottom: [] 9 | kilnInternals: 10 | - 11 | _ref: /_components/clay-kiln 12 | -------------------------------------------------------------------------------- /app/.stylelintrc.yml: -------------------------------------------------------------------------------- 1 | plugins: 2 | - stylelint-order 3 | rules: 4 | declaration-no-important: [true, {severity: warning}] 5 | max-nesting-depth: 2 6 | order/order: [dollar-variables, at-variables, declarations, rules, at-rules] 7 | order/properties-alphabetical-order: true 8 | -------------------------------------------------------------------------------- /app/components/article/media/icon-special-feature.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/components/image/media/ar-square.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/components/image/media/ar-vertical.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/components/article/media/icon-feed-square.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/components/image/media/ar-horizontal.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/components/paragraph/model.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | const sanitize = require('../../services/universal/sanitize'); 4 | 5 | module.exports.save = function(ref, data) { 6 | data.text = sanitize.validateTagContent(sanitize.toSmartText(data.text || '')); 7 | 8 | return data; 9 | }; 10 | -------------------------------------------------------------------------------- /app/sites/claydemo/config.yml: -------------------------------------------------------------------------------- 1 | name: ${CLAY_SITE_NAME} 2 | host: ${CLAY_SITE_HOST} 3 | path: ${CLAY_SITE_PATH} 4 | assetDir: public 5 | assetPath: ${CLAY_SITE_PATH} 6 | port: ${CLAY_SITE_PORT} 7 | protocol: ${CLAY_SITE_PROTOCOL} 8 | shortKey: ${CLAY_SITE_SHORTKEY} 9 | styleguide: claydemo 10 | -------------------------------------------------------------------------------- /app/components/article/media/icon-feed-noimg.svg: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /app/components/article/media/icon-inline.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/components/divider/schema.yml: -------------------------------------------------------------------------------- 1 | _description: | 2 | A simple divider between other components. Can provide an optional title for the divider. 3 | 4 | title: 5 | _label: Divider Title 6 | _placeholder: 7 | height: 20px 8 | text: Divider Title 9 | _has: 10 | input: inline 11 | -------------------------------------------------------------------------------- /app/components/meta-url/template.handlebars: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | {{#if date}} 5 | 6 | {{/if}} 7 | -------------------------------------------------------------------------------- /app/components/image/media/ar-deep-vertical.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.github/PULL_REQUEST_TEMPLATE.md: -------------------------------------------------------------------------------- 1 | ## What does this PR do? 2 | 3 | [Issue/Story](LINK_TO_STORY) 4 | 5 | ### Why are we doing this? Any context or related work? 6 | 7 | #### Where should a reviewer start? 8 | 9 | ### Manual testing steps? 10 | 11 | ##### Screenshots 12 | 13 | ### Additional Context 14 | -------------------------------------------------------------------------------- /app/components/header/model.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | module.exports.save = function(uri, data) { 4 | if (data.siteLogo) { 5 | data.isSVGString = 6 | data.siteLogo 7 | .trim() 8 | .substr(0, 4) 9 | .toLowerCase() === ' -------------------------------------------------------------------------------- /app/components/subheader/media/icon-link.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/components/article/media/icon-feed-thumb.svg: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /app/components/footer/template.hbs: -------------------------------------------------------------------------------- 1 | 11 | -------------------------------------------------------------------------------- /app/components/subheader/template.hbs: -------------------------------------------------------------------------------- 1 | <{{type}} class="{{ componentVariation }}" data-editable="subheader" data-uri="{{default _ref _self}}" id={{subheaderId}}> 2 | {{{text}}} 3 | {{#if text}} 4 | 5 | {{{ read 'public/media/components/subheader/icon-link.svg' }}} 6 | 7 | {{/if}} 8 | {{type}}> 9 | -------------------------------------------------------------------------------- /app/components/image/media/size-breakout.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/components/image/media/size-inline.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/components/meta-keywords/schema.yml: -------------------------------------------------------------------------------- 1 | _description: | 2 | Adds `article:tag` (schema.org) tags to the head. 3 | 4 | tags: 5 | _label: Tags 6 | _display: settings 7 | _subscribe: keywords 8 | _has: 9 | - simple-list 10 | - label 11 | - 12 | fn: description 13 | value: Array of tags. These will become comma-separated in the template. 14 | -------------------------------------------------------------------------------- /app/components/subheader/model.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | const sanitize = require('../../services/universal/sanitize'); 4 | 5 | module.exports.save = function(ref, data) { 6 | data.text = sanitize.validateTagContent(sanitize.toSmartText(data.text || '')); 7 | data.subheaderId = `${data.subheaderId || data.text}`.trim().replace(/\s+/g, '-'); 8 | return data; 9 | }; 10 | -------------------------------------------------------------------------------- /app/components/meta-title/template.handlebars: -------------------------------------------------------------------------------- 1 | 2 | {{#if @root.locals.edit}} 3 |{{{html}}}
6 | {{/if}}
7 | {{tagline}}
18 | {{/if}} 19 | {{#if enableSocialButtons}} 20 | 40 | {{/if}} 41 |