diff --git a/.eslintrc.json b/.eslintrc.json new file mode 100644 index 0000000..63ae766 --- /dev/null +++ b/.eslintrc.json @@ -0,0 +1,42 @@ +{ + "env": { + "browser": true, + "es2021": true + }, + "extends": [ + "plugin:react/recommended", + "plugin:react/jsx-runtime", + "standard-with-typescript", + "plugin:prettier/recommended" + ], + "overrides": [], + "parserOptions": { + "ecmaVersion": "latest", + "sourceType": "module", + "project": ["./tsconfig.json"] + }, + "plugins": ["react", "prettier"], + "rules": { + "react/display-name": "off", + "@typescript-eslint/explicit-function-return-type": "off", + "react/prop-types": "off", + "@typescript-eslint/restrict-template-expressions": "off", + "@typescript-eslint/strict-boolean-expressions": "off", + "@typescript-eslint/prefer-nullish-coalescing": "off", + "@typescript-eslint/no-empty-interface": "off", + "@typescript-eslint/consistent-type-assertions": "off", + "@typescript-eslint/no-dynamic-delete": "off", + "react/jsx-curly-brace-presence": [ + "error", + { + "props": "never", + "children": "never" + } + ] + }, + "settings": { + "react": { + "version": "detect" + } + } +} diff --git a/.fttemplates/Component/[FTName].stories.tsx b/.fttemplates/Component/[FTName].stories.tsx new file mode 100644 index 0000000..8f1ab79 --- /dev/null +++ b/.fttemplates/Component/[FTName].stories.tsx @@ -0,0 +1,17 @@ +import {ComponentMeta, Story} from '@storybook/react' +import React from 'react' +import {[FTName]} from './[FTName].js' +export default { + title: 'Components/[FTName]', + component: [FTName], + parameters: { + layout: 'fullscreen' + } +} as ComponentMeta + +type ComponentProps = React.ComponentProps + +// Create a template for the component +const Template: Story = args => <[FTName] {...args} /> + +export const Basic: Story = Template.bind({}) diff --git a/.fttemplates/Component/[FTName].tsx b/.fttemplates/Component/[FTName].tsx new file mode 100644 index 0000000..103ff46 --- /dev/null +++ b/.fttemplates/Component/[FTName].tsx @@ -0,0 +1,7 @@ +export interface [FTName]Props {} + +export const [FTName]: React.FC<[FTName]Props> = props => { + return <> +

[FTName]

+ +} \ No newline at end of file diff --git a/.fttemplates/Component/index.ts b/.fttemplates/Component/index.ts new file mode 100644 index 0000000..90ba72b --- /dev/null +++ b/.fttemplates/Component/index.ts @@ -0,0 +1 @@ +export {[FTName], type [FTName]Props} from './[FTName]' \ No newline at end of file diff --git a/.github/workflows/jaen-deploy.yaml b/.github/workflows/jaen-deploy.yaml new file mode 100644 index 0000000..8d20613 --- /dev/null +++ b/.github/workflows/jaen-deploy.yaml @@ -0,0 +1,169 @@ +# SPDX-FileCopyrightText: Copyright Β© 2021 snek.at +# SPDX-License-Identifier: EUPL-1.2 +# +# Use of this source code is governed by an EUPL-1.2 license that can be found +# in the LICENSE file at https://snek.at/license + +# Workflow name +# See: https://help.github.com/en/articles/workflow-syntax-for-github-actions#name +name: Deploy Jaen + +# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages +permissions: + contents: read + pages: write + id-token: write + +# Allow one concurrent deployment +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + +# Default to bash +defaults: + run: + shell: bash + +# Workflow trigger +# See: https://help.github.com/en/articles/workflow-syntax-for-github-actions#on +on: + # Workflow call trigger + # See: https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#onworkflow_call + workflow_call: + # Workflow call inputs + # See: https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#onworkflow_callinputs + inputs: + CLOUDFLARE_PROJECT_NAME: + description: 'The name of the project in Cloudflare' + required: false + type: 'string' + # Workflow call secrets + # See: https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#onworkflow_callsecrets + secrets: + CLOUDFLARE_ACCOUNT_ID: + description: Cloudflare account id. + required: false + CLOUDFLARE_API_TOKEN: + description: Cloudflare api key. + required: false + SCALE_SERP_APIKEY: + description: Scale Serp api key. + required: false + SCALE_SERP_GOOGLE_PLACE_ID: + description: Place IDs uniquely identify a place in the Google Places database and on Google Maps. + required: false + GATSBY_MYSHOPIFY_URL: + description: Domain for a Shopify shop (foo.myshopify.com). + required: false + GATSBY_STOREFRONT_API_KEY: + description: Key for Shopify Storefront API. + required: false + SHOPIFY_APP_PASSWORD: + description: Personal access token for a Shopify account. + required: false + SENDGRID_API_KEY: + description: SendGrid api key. + required: false + GATSBY_MAPBOX_ACCESS_TOKEN: + description: Mapbox access token. + required: false + GATSBY_SNEK_FUNCTION_URL: + description: URL of the Snek function. + required: false + SENTRY_AUTH_TOKEN: + description: Sentry token. + required: false + +# Environment variables +# See: https://help.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#env +env: + NODE_OPTIONS: --max-old-space-size=8192 + +# Jobs +# See: https://help.github.com/en/articles/workflow-syntax-for-github-actions#jobs +jobs: + # Job id + # See: https://help.github.com/en/articles/workflow-syntax-for-github-actions#jobsjob_id + jaen-deploy: + # Runs on ubuntu-latest + # See: https://help.github.com/en/articles/workflow-syntax-for-github-actions#jobsjob_idruns-on + runs-on: ubuntu-latest + + defaults: + run: + # Working directory + # See: https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun + working-directory: ${{ github.event.client_payload.cwd || '.' }} + + # Steps + # See: https://help.github.com/en/articles/workflow-syntax-for-github-actions#jobsjob_idsteps + steps: + # Checkout step + # See: https://github.com/actions/checkout + - name: Checkout πŸ›ŽοΈ + uses: actions/checkout@v4 + with: + # Relative path under $GITHUB_WORKSPACE to place the repository + path: "." + ref: ${{github.ref}} + fetch-depth: 0 + + - name: Detect package manager πŸ” + id: detect-package-manager + run: | + if [ -f "${{ github.workspace }}/yarn.lock" ]; then + echo "manager=yarn" >> $GITHUB_OUTPUT + echo "command=install" >> $GITHUB_OUTPUT + exit 0 + elif [ -f "${{ github.workspace }}/package.json" ]; then + echo "manager=npm" >> $GITHUB_OUTPUT + echo "command=ci" >> $GITHUB_OUTPUT + exit 0 + else + echo "Unable to determine packager manager" + exit 1 + fi + + - name: Setup Node πŸ”§ + uses: actions/setup-node@v3 + with: + node-version: "18" + cache: ${{ steps.detect-package-manager.outputs.manager }} + + - name: Install dependencies πŸ“¦ + run: ${{ steps.detect-package-manager.outputs.manager }} ${{ steps.detect-package-manager.outputs.command }} + + - name: Restore cache πŸ—„οΈ + uses: actions/cache@v3 + with: + path: | + public + .cache + key: ${{ runner.os }}-gatsby-build-${{ hashFiles('public') }} + restore-keys: | + ${{ runner.os }}-gatsby-build- + + - name: Build with Gatsby πŸ› οΈ + run: + ${{ steps.detect-package-manager.outputs.manager }} run build + env: + PREFIX_PATHS: 'true' + GATSBY_MYSHOPIFY_URL: ${{ secrets.GATSBY_MYSHOPIFY_URL }} + GATSBY_STOREFRONT_API_KEY: ${{ secrets.GATSBY_STOREFRONT_API_KEY }} + SHOPIFY_APP_PASSWORD: ${{ secrets.SHOPIFY_APP_PASSWORD }} + SCALE_SERP_APIKEY: ${{ secrets.SCALE_SERP_APIKEY }} + SCALE_SERP_GOOGLE_PLACE_ID: ${{ secrets.SCALE_SERP_GOOGLE_PLACE_ID }} + SENDGRID_API_KEY: ${{ secrets.SENDGRID_API_KEY }} + GATSBY_MAPBOX_ACCESS_TOKEN: ${{ secrets.GATSBY_MAPBOX_ACCESS_TOKEN }} + SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }} + + - name: Deploy Cloudflare Pages πŸš€ + # See: https://github.com/cloudflare/pages-action + uses: cloudflare/pages-action@v1 + with: + apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} + accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} + projectName: ${{ inputs.CLOUDFLARE_PROJECT_NAME }} + directory: ./public + # Optional: Specify the Wrangler version + wranglerVersion: '3' diff --git a/.github/workflows/jaen-publish.yaml b/.github/workflows/jaen-publish.yaml new file mode 100644 index 0000000..9328dc0 --- /dev/null +++ b/.github/workflows/jaen-publish.yaml @@ -0,0 +1,99 @@ +# SPDX-FileCopyrightText: Copyright Β© 2021 snek.at +# SPDX-License-Identifier: EUPL-1.2 +# +# Use of this source code is governed by an EUPL-1.2 license that can be found +# in the LICENSE file at https://snek.at/license + +# https://help.github.com/en/articles/workflow-syntax-for-github-actions#name +name: Jaen Publish + +# https://help.github.com/en/articles/workflow-syntax-for-github-actions#on +on: + # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#onworkflow_call + workflow_call: + # https://docs.github.com/en/enterprise-cloud@latest/actions/using-workflows/workflow-syntax-for-github-actions#onworkflow_callinputs + inputs: + JAEN_MIGRATION_URL: + description: Link to the Jaen migrations file. + # https://docs.github.com/en/enterprise-cloud@latest/actions/using-workflows/workflow-syntax-for-github-actions#onworkflow_callinputsinput_idtype + type: string + required: false + WORKING_DIRECTORY: + description: Path to working directory in a monorepo. + # https://docs.github.com/en/enterprise-cloud@latest/actions/using-workflows/workflow-syntax-for-github-actions#onworkflow_callinputsinput_idtype + type: string + required: false + +# https://help.github.com/en/articles/workflow-syntax-for-github-actions#jobs +jobs: + # https://help.github.com/en/articles/workflow-syntax-for-github-actions#jobsjob_id + jaen-publish: + # https://help.github.com/en/articles/workflow-syntax-for-github-actions#jobsjob_idruns-on + runs-on: ubuntu-latest + defaults: + run: + # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions# + working-directory: ${{ inputs.WORKING_DIRECTORY }} + # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsenv + env: + JAEN_MIGRATION_URL: ${{ inputs.JAEN_MIGRATION_URL }} + + # https://help.github.com/en/articles/workflow-syntax-for-github-actions#jobsjob_idsteps + steps: + # https://github.com/actions/checkout + - name: Checkout πŸ›ŽοΈ + uses: actions/checkout@v3 + # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepswith + with: + # Relative path under $GITHUB_WORKSPACE to place the repository + path: "." + + # https://dev.to/mpocock1/how-to-cache-nodemodules-in-github-actions-with-yarn-24eh + - name: Yarn Cache Directory Path + id: yarn-cache-dir-path + # https://help.github.com/en/articles/workflow-syntax-for-github-actions#jobsjob_idstepsrun + run: echo "::set-output name=dir::$(yarn cache dir)" + + # https://github.com/marketplace/actions/cache + - name: Yarn Cache Folder + uses: actions/cache@v3 + # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepswith + with: + # https://help.github.com/en/articles/virtual-environments-for-github-actions#default-environment-variables + path: ${{ steps.yarn-cache-dir-path.outputs.dir }} + key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} + restore-keys: ${{ runner.os }}-yarn- + + # https://github.com/marketplace/actions/cache + - name: Yarn Cache Node + uses: actions/cache@v3 + # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepswith + with: + path: "**/node_modules" + key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }} + + # https://classic.yarnpkg.com/lang/en/docs/cli/install/#toc-yarn-install-pure-lockfile + - name: Yarn Install + # https://help.github.com/en/articles/workflow-syntax-for-github-actions#jobsjob_idstepsrun + run: yarn install --pure-lockfile + + # https://help.github.com/en/articles/workflow-syntax-for-github-actions#jobsjob_idstepsid + - name: Configure GitHub Authentication πŸ”§ + # https://help.github.com/en/articles/workflow-syntax-for-github-actions#jobsjob_idstepsrun + run: | + # Git: set identity + git config user.name "snekmin" + git config user.email "noreply.snek.at@gmail.com" + + # Git: set remote + # https://developer.github.com/apps/building-github-apps/authenticating-with-github-apps/#http-based-git-access-by-an-installation + git remote set-url origin "https://x-access-token:${{secrets.GITHUB_TOKEN}}@github.com/${GITHUB_REPOSITORY}.git" + + # https://help.github.com/en/articles/workflow-syntax-for-github-actions#jobsjob_idstepsid + - name: Update patches.txt with JAEN_MIGRATION_URL + # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions# + working-directory: ${{ inputs.WORKING_DIRECTORY }} + # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsif + if: ${{ inputs.JAEN_MIGRATION_URL }} + # https://help.github.com/en/articles/workflow-syntax-for-github-actions#jobsjob_idstepsrun + run: echo "${{ env.JAEN_MIGRATION_URL }}" >> ./jaen-data/patches.txt diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..68843fd --- /dev/null +++ b/.gitignore @@ -0,0 +1,10 @@ +.cache +public +node_modules +.npmrc + +.DS_Store + +**/dist + +**/tsconfig.tsbuildinfo \ No newline at end of file diff --git a/.prettierrc.json b/.prettierrc.json new file mode 100644 index 0000000..2e33864 --- /dev/null +++ b/.prettierrc.json @@ -0,0 +1,12 @@ +{ + "printWidth": 80, + "tabWidth": 2, + "useTabs": false, + "semi": false, + "singleQuote": true, + "trailingComma": "none", + "bracketSpacing": false, + "arrowParens": "avoid", + "bracketSameLine": true, + "jsxBracketSameLine": true +} diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..3eefb63 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,8 @@ +{ + "typescript.tsdk": "node_modules/typescript/lib", + "editor.codeActionsOnSave": { + "source.fixAll.eslint": "explicit", + "source.fixAll.tslint": "explicit", + "source.fixAll.stylelint": "explicit" + } +} diff --git a/babel.config.json b/babel.config.json new file mode 100644 index 0000000..b5cf683 --- /dev/null +++ b/babel.config.json @@ -0,0 +1,16 @@ +{ + "sourceType": "unambiguous", + "presets": [ + [ + "@babel/preset-env", + { + "targets": { + "chrome": 100 + } + } + ], + "@babel/preset-typescript", + "@babel/preset-react" + ], + "plugins": [] +} \ No newline at end of file diff --git a/examples/my-gatsby-site/.env b/examples/my-gatsby-site/.env new file mode 100644 index 0000000..2c5b3ad --- /dev/null +++ b/examples/my-gatsby-site/.env @@ -0,0 +1,2 @@ +GATSBY_LENS_API_URL=https://api.photonq.lens.atsnek.com/graphql +#SENTRY_AUTH_TOKEN=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 diff --git a/examples/my-gatsby-site/.gitignore b/examples/my-gatsby-site/.gitignore index 557f97c..5282102 100644 --- a/examples/my-gatsby-site/.gitignore +++ b/examples/my-gatsby-site/.gitignore @@ -1,3 +1,4 @@ node_modules/ .cache/ public +src/gatsby-types.d.ts diff --git a/examples/my-gatsby-site/CHANGELOG.md b/examples/my-gatsby-site/CHANGELOG.md deleted file mode 100644 index 4ba4f57..0000000 --- a/examples/my-gatsby-site/CHANGELOG.md +++ /dev/null @@ -1,404 +0,0 @@ -# [my-gatsby-site-v1.1.0](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0...my-gatsby-site-v1.1.0) (2021-11-22) - - -### Features - -* **jaen-pages:** switch from ipfs to osg ([3e9df13](https://github.com/snek-at/jaen/commit/3e9df13598944ad546aa36b2a52594c4d900478f)) - -# my-gatsby-site-v1.0.0 (2021-09-27) - - -### Bug Fixes - -* **.babelrc:** add preset-react ([36a0f2c](https://github.com/snek-at/jaen/commit/36a0f2cba18b74a4a2a20e94bdc9d61f29c7089b)) -* **blockcontainer:** add workaround to bypass field registration inside a block container ([2e55edf](https://github.com/snek-at/jaen/commit/2e55edfe0a168b2cc91fa9bf8ac3be13fcda35d1)) -* **blockcontainer:** disable SFBWrapper when not editing ([a171b96](https://github.com/snek-at/jaen/commit/a171b9610718864037f2a2fe5b4de44369886e2f)) -* **chakra:** reset css ([2d1d195](https://github.com/snek-at/jaen/commit/2d1d1956ae3c61f188696ea268625395cb1ffe37)) -* **choicefield:** enable popover only on editing ([4ee9231](https://github.com/snek-at/jaen/commit/4ee923178ab30045d44f0d74ec85c8995bc02c52)) -* **fields:** remove WA, add block registration and fix missing block data ([fb4c2df](https://github.com/snek-at/jaen/commit/fb4c2df08b8129b48245238736bd6d767d69f47b)) -* **gatsby-node:** add missing slug on fixed pages that are not the index ([81eb4c5](https://github.com/snek-at/jaen/commit/81eb4c5bce7dc0f27ca2fed500d7336ed65de6df)) -* **gatsby-node:** fix variable not defined error ([0013d08](https://github.com/snek-at/jaen/commit/0013d08882d6c3188508c70caee85d1272e60bbe)) -* **imagefield:** blinking on hover when using position absolut fixed ([d45c6f9](https://github.com/snek-at/jaen/commit/d45c6f92906bcb2acb271056fb94a6a9a832cda2)) -* **indexfield:** fix page context ([74d6383](https://github.com/snek-at/jaen/commit/74d6383c5e52600dc64640e2e0e44c492110b758)) -* **jaen-pages cli:** fix cli typescript error ([780c4af](https://github.com/snek-at/jaen/commit/780c4af97387254f24d01580486badbc3fa8efd2)) -* **package.json:** align monorepo package versions ([69661f7](https://github.com/snek-at/jaen/commit/69661f761edc4aa6c0839cb0a588dd328ec098a5)) -* **package.json:** align versions ([cfd6201](https://github.com/snek-at/jaen/commit/cfd6201a2212063a65b7d17d9d1d0097a0cd7b62)) -* **package.json:** align versions ([e28c4c9](https://github.com/snek-at/jaen/commit/e28c4c93e5294e44d446d80b311826d577813163)) -* **package.json:** align versions ([5f0e61a](https://github.com/snek-at/jaen/commit/5f0e61a2425e43b7a38d58bf2e29be2802f639e1)) -* **package.json:** align versions ([0bedf29](https://github.com/snek-at/jaen/commit/0bedf29c917a4d755ac48c3220725ac6f22fe7ac)) -* **package.json:** align versions ([a7b59a3](https://github.com/snek-at/jaen/commit/a7b59a3ac9f7d81bb6efcb5a2a866e138f7969cc)) -* **package.json:** fix versions ([16c706c](https://github.com/snek-at/jaen/commit/16c706c328db52088ee1d521ab5c69c715221267)) -* **package.json:** update version ([fe2aa5a](https://github.com/snek-at/jaen/commit/fe2aa5a3c8a24533cf12497f1c96166cfd91b159)) -* **package.json:** update versions ([8ce78ef](https://github.com/snek-at/jaen/commit/8ce78ef6a1b494f06428845f9470fe0717a030f3)) -* **publish:** publishing works also without page changes now ([a091153](https://github.com/snek-at/jaen/commit/a0911534a067e417849ba70e4c3d0407bfc447fc)) -* **seo:** fix page image url ([5e55706](https://github.com/snek-at/jaen/commit/5e55706837336e541c8243360e18ce8890de7dbc)) -* **theme:** update jaen themes ([3d7921f](https://github.com/snek-at/jaen/commit/3d7921f836e587844c12a59f398c106e39015c36)) -* add high zIndex to MainUI toggle button ([c180d92](https://github.com/snek-at/jaen/commit/c180d92678ce27e499bd9dcb10755de44732b3e1)) -* add portal and zindex to mainui ([12f6aed](https://github.com/snek-at/jaen/commit/12f6aed5d5cbdad208d92a1d6d7d3347e6e0a7a9)) -* disable page updating on page change ([cbd2656](https://github.com/snek-at/jaen/commit/cbd2656579947d62e03efaf00212ee6533d2cb95)) -* enable image creation for none jaen pages ([5a4d4d4](https://github.com/snek-at/jaen/commit/5a4d4d4c6162bfd181d2eec895fea6e3ef986578)) -* enable transpiling ([037856a](https://github.com/snek-at/jaen/commit/037856a4bad791be351cc03b2afb29c65f9b8bff)) -* fix versions ([fb37799](https://github.com/snek-at/jaen/commit/fb37799fb95fa47dbf2adee3a3ab462c636e9fe9)) -* improve file creating and jaen plugin register ([6a32003](https://github.com/snek-at/jaen/commit/6a3200390217a21eb57d962022681d05e5acff84)) -* resolve paths for publish pages ([4fea93f](https://github.com/snek-at/jaen/commit/4fea93fdb5b8a47e3b6d03488178b87d61e89016)) -* **package.json:** align versions ([07a4c3a](https://github.com/snek-at/jaen/commit/07a4c3a1937d9aae57214457d04bc9e2fdf316d3)) -* **package.json:** align versions ([35e74c1](https://github.com/snek-at/jaen/commit/35e74c170d136f28676228e8726794aec45cb642)) -* **package.json:** align versions ([ca6fc14](https://github.com/snek-at/jaen/commit/ca6fc14c3ac34e6853d3c3d6afa894fe10dae445)) -* **package.json:** update snekfinder version ([a764f35](https://github.com/snek-at/jaen/commit/a764f354abc83e43bf355c4efee57dc4c7e2b1d4)) -* page creaction and esm ([ab3bbda](https://github.com/snek-at/jaen/commit/ab3bbdabc37ae4ef14044bd6b29c4dfb80254362)) -* remove transpiling ([9ec9b59](https://github.com/snek-at/jaen/commit/9ec9b59b69515bbdf3c47b77c9434ce2b38632f3)) - - -### Features - -* **blockcontainer:** enable wrap for container ([504dd50](https://github.com/snek-at/jaen/commit/504dd508ac13f83ccafca3764eb6144a294b1299)) -* **chakraui:** enfore chakraui through jaen ([bd539de](https://github.com/snek-at/jaen/commit/bd539de1513f7656f5a7a5ce2f30c8c1628f8967)) -* **choicefield:** add disable option for popover ([91a36ac](https://github.com/snek-at/jaen/commit/91a36ac01c4899d5a284b53c55e8e1416a125cbb)) -* **mainui:** add option to initially hide ui ([0d4a063](https://github.com/snek-at/jaen/commit/0d4a0630880f2d4cb53ec4637b784ae1a6496f6e)) -* **mainui:** provide hideUI status through core provider ([2288635](https://github.com/snek-at/jaen/commit/228863568f75c68e127e143b47c0bc90ed5c2bf1)) -* **release:** update to v2.0.0 ([3093c33](https://github.com/snek-at/jaen/commit/3093c33b57996686fd8049d1201826a540024bc7)) -* **seo:** add react helmet gatsby plugin to ssr meta tags ([5490aa7](https://github.com/snek-at/jaen/commit/5490aa72fc071c256b11ee4f6c26bb19a339203c)) -* **seo:** add SEO to TemplateProvider ([38fc053](https://github.com/snek-at/jaen/commit/38fc0531adfbb7f58d96f6cbc3d86b7b94dbe18d)) -* **snekfinder:** sync files on publish ([b67a68c](https://github.com/snek-at/jaen/commit/b67a68c3a18debee9ba91f97ed4ebe512ee6b75d)) -* add ChoiceField ([115417b](https://github.com/snek-at/jaen/commit/115417b7a0fc9aca684df8ee068a87d58ce365bb)) -* add gatsby publishing ([83d2704](https://github.com/snek-at/jaen/commit/83d270482c60a7783b408c7f954e8e148e51e741)) -* add jaen-pages cli ([b2a9724](https://github.com/snek-at/jaen/commit/b2a972405f307e1682f5f72a23c1f026bbe9f2bb)) -* add jaen-pages migration workflow ([008918c](https://github.com/snek-at/jaen/commit/008918cc1c8d8ee88ad914f674b978ebc68e21c6)) -* add jaenPageContext ([2bf4da1](https://github.com/snek-at/jaen/commit/2bf4da1a154de2db83ebbec6fad5cfa3a758053b)) -* enable childpages for static pages ([c8f442e](https://github.com/snek-at/jaen/commit/c8f442e58f0d83367abd821c29ec822837a10e45)) -* introduce BlockContainer (StreamField replacement) ([e89c100](https://github.com/snek-at/jaen/commit/e89c1002b05ed33f69240b128d129ddbea5cb362)) -* jaenImage uses GatsbyImage now ([a28b99e](https://github.com/snek-at/jaen/commit/a28b99ec0e6bd83cb6359c4ff4783f6847e6a3a4)) -* remove initialValue form StreamField ([1c60e15](https://github.com/snek-at/jaen/commit/1c60e15311338ff2f060269ed81812a4ef2b655a)) -* send publish request on button press ([75d5cfc](https://github.com/snek-at/jaen/commit/75d5cfcb35bcde7e7f3d455b44b9921e1dd2eefa)) -* streamField not includes build data ([b12ff24](https://github.com/snek-at/jaen/commit/b12ff24803c3c7e82971fbe252bb0c333fec469e)) - - -### Performance Improvements - -* **ckeditor:** load bundle only if editing is true (prevents from loading it to SSR) ([acabb30](https://github.com/snek-at/jaen/commit/acabb308285769a7d2beb666b2097a82822f273e)) -* **ckeditor:** only render if `defaultData.shouldOverrideRand` changes ([61361dc](https://github.com/snek-at/jaen/commit/61361dc785f21ec38b1df25d321cf4c3fcd8e1a5)) -* use dynamic imports to reduce the bundle size ([712dfe3](https://github.com/snek-at/jaen/commit/712dfe3f8fb970ffc1ce7fbd9e3cf34f5b183985)) - - -### BREAKING CHANGES - -* **release:** Update to v2.0.0 - -# [my-gatsby-site-v1.0.0-beta.37](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.36...my-gatsby-site-v1.0.0-beta.37) (2021-09-27) - - -### Features - -* **snekfinder:** sync files on publish ([b67a68c](https://github.com/snek-at/jaen/commit/b67a68c3a18debee9ba91f97ed4ebe512ee6b75d)) - -# [my-gatsby-site-v1.0.0-beta.36](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.35...my-gatsby-site-v1.0.0-beta.36) (2021-09-26) - - -### Features - -* **mainui:** provide hideUI status through core provider ([2288635](https://github.com/snek-at/jaen/commit/228863568f75c68e127e143b47c0bc90ed5c2bf1)) - -# [my-gatsby-site-v1.0.0-beta.35](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.34...my-gatsby-site-v1.0.0-beta.35) (2021-09-26) - - -### Bug Fixes - -* **package.json:** align versions ([cfd6201](https://github.com/snek-at/jaen/commit/cfd6201a2212063a65b7d17d9d1d0097a0cd7b62)) - - -### Features - -* **mainui:** add option to initially hide ui ([0d4a063](https://github.com/snek-at/jaen/commit/0d4a0630880f2d4cb53ec4637b784ae1a6496f6e)) - -# [my-gatsby-site-v1.0.0-beta.34](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.33...my-gatsby-site-v1.0.0-beta.34) (2021-09-16) - - -### Bug Fixes - -* **seo:** fix page image url ([5e55706](https://github.com/snek-at/jaen/commit/5e55706837336e541c8243360e18ce8890de7dbc)) - -# [my-gatsby-site-v1.0.0-beta.33](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.32...my-gatsby-site-v1.0.0-beta.33) (2021-09-16) - - -### Features - -* **seo:** add react helmet gatsby plugin to ssr meta tags ([5490aa7](https://github.com/snek-at/jaen/commit/5490aa72fc071c256b11ee4f6c26bb19a339203c)) - -# [my-gatsby-site-v1.0.0-beta.32](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.31...my-gatsby-site-v1.0.0-beta.32) (2021-09-16) - - -### Bug Fixes - -* **gatsby-node:** add missing slug on fixed pages that are not the index ([81eb4c5](https://github.com/snek-at/jaen/commit/81eb4c5bce7dc0f27ca2fed500d7336ed65de6df)) - -# [my-gatsby-site-v1.0.0-beta.31](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.30...my-gatsby-site-v1.0.0-beta.31) (2021-09-15) - - -### Bug Fixes - -* **imagefield:** blinking on hover when using position absolut fixed ([d45c6f9](https://github.com/snek-at/jaen/commit/d45c6f92906bcb2acb271056fb94a6a9a832cda2)) - -# [my-gatsby-site-v1.0.0-beta.30](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.29...my-gatsby-site-v1.0.0-beta.30) (2021-09-15) - - -### Performance Improvements - -* **ckeditor:** load bundle only if editing is true (prevents from loading it to SSR) ([acabb30](https://github.com/snek-at/jaen/commit/acabb308285769a7d2beb666b2097a82822f273e)) -* **ckeditor:** only render if `defaultData.shouldOverrideRand` changes ([61361dc](https://github.com/snek-at/jaen/commit/61361dc785f21ec38b1df25d321cf4c3fcd8e1a5)) - -# [my-gatsby-site-v1.0.0-beta.29](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.28...my-gatsby-site-v1.0.0-beta.29) (2021-09-15) - - -### Bug Fixes - -* **gatsby-node:** fix variable not defined error ([0013d08](https://github.com/snek-at/jaen/commit/0013d08882d6c3188508c70caee85d1272e60bbe)) - -# [my-gatsby-site-v1.0.0-beta.28](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.27...my-gatsby-site-v1.0.0-beta.28) (2021-09-14) - - -### Bug Fixes - -* **publish:** publishing works also without page changes now ([a091153](https://github.com/snek-at/jaen/commit/a0911534a067e417849ba70e4c3d0407bfc447fc)) - - -### Performance Improvements - -* use dynamic imports to reduce the bundle size ([712dfe3](https://github.com/snek-at/jaen/commit/712dfe3f8fb970ffc1ce7fbd9e3cf34f5b183985)) - -# [my-gatsby-site-v1.0.0-beta.27](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.26...my-gatsby-site-v1.0.0-beta.27) (2021-09-14) - - -### Bug Fixes - -* **fields:** remove WA, add block registration and fix missing block data ([fb4c2df](https://github.com/snek-at/jaen/commit/fb4c2df08b8129b48245238736bd6d767d69f47b)) -* **package.json:** align versions ([e28c4c9](https://github.com/snek-at/jaen/commit/e28c4c93e5294e44d446d80b311826d577813163)) - -# [my-gatsby-site-v1.0.0-beta.26](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.25...my-gatsby-site-v1.0.0-beta.26) (2021-09-14) - - -### Bug Fixes - -* **blockcontainer:** add workaround to bypass field registration inside a block container ([2e55edf](https://github.com/snek-at/jaen/commit/2e55edfe0a168b2cc91fa9bf8ac3be13fcda35d1)) -* **package.json:** align versions ([5f0e61a](https://github.com/snek-at/jaen/commit/5f0e61a2425e43b7a38d58bf2e29be2802f639e1)) - -# [my-gatsby-site-v1.0.0-beta.25](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.24...my-gatsby-site-v1.0.0-beta.25) (2021-09-14) - - -### Bug Fixes - -* **package.json:** align versions ([0bedf29](https://github.com/snek-at/jaen/commit/0bedf29c917a4d755ac48c3220725ac6f22fe7ac)) - -# [my-gatsby-site-v1.0.0-beta.24](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.23...my-gatsby-site-v1.0.0-beta.24) (2021-09-13) - - -### Features - -* **seo:** add SEO to TemplateProvider ([38fc053](https://github.com/snek-at/jaen/commit/38fc0531adfbb7f58d96f6cbc3d86b7b94dbe18d)) - -# [my-gatsby-site-v1.0.0-beta.23](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.22...my-gatsby-site-v1.0.0-beta.23) (2021-09-13) - - -### Bug Fixes - -* **package.json:** align versions ([a7b59a3](https://github.com/snek-at/jaen/commit/a7b59a3ac9f7d81bb6efcb5a2a866e138f7969cc)) - -# [my-gatsby-site-v1.0.0-beta.22](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.21...my-gatsby-site-v1.0.0-beta.22) (2021-09-12) - - -### Bug Fixes - -* **theme:** update jaen themes ([3d7921f](https://github.com/snek-at/jaen/commit/3d7921f836e587844c12a59f398c106e39015c36)) - -# [my-gatsby-site-v1.0.0-beta.21](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.20...my-gatsby-site-v1.0.0-beta.21) (2021-09-12) - - -### Bug Fixes - -* enable image creation for none jaen pages ([5a4d4d4](https://github.com/snek-at/jaen/commit/5a4d4d4c6162bfd181d2eec895fea6e3ef986578)) -* fix versions ([fb37799](https://github.com/snek-at/jaen/commit/fb37799fb95fa47dbf2adee3a3ab462c636e9fe9)) -* improve file creating and jaen plugin register ([6a32003](https://github.com/snek-at/jaen/commit/6a3200390217a21eb57d962022681d05e5acff84)) -* resolve paths for publish pages ([4fea93f](https://github.com/snek-at/jaen/commit/4fea93fdb5b8a47e3b6d03488178b87d61e89016)) - -# [my-gatsby-site-v1.0.0-beta.20](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.19...my-gatsby-site-v1.0.0-beta.20) (2021-09-10) - - -### Bug Fixes - -* add portal and zindex to mainui ([12f6aed](https://github.com/snek-at/jaen/commit/12f6aed5d5cbdad208d92a1d6d7d3347e6e0a7a9)) - - -### Features - -* **blockcontainer:** enable wrap for container ([504dd50](https://github.com/snek-at/jaen/commit/504dd508ac13f83ccafca3764eb6144a294b1299)) -* enable childpages for static pages ([c8f442e](https://github.com/snek-at/jaen/commit/c8f442e58f0d83367abd821c29ec822837a10e45)) - -# [my-gatsby-site-v1.0.0-beta.19](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.18...my-gatsby-site-v1.0.0-beta.19) (2021-09-10) - - -### Bug Fixes - -* **package.json:** align versions ([07a4c3a](https://github.com/snek-at/jaen/commit/07a4c3a1937d9aae57214457d04bc9e2fdf316d3)) - -# [my-gatsby-site-v1.0.0-beta.18](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.17...my-gatsby-site-v1.0.0-beta.18) (2021-09-10) - - -### Bug Fixes - -* **jaen-pages cli:** fix cli typescript error ([780c4af](https://github.com/snek-at/jaen/commit/780c4af97387254f24d01580486badbc3fa8efd2)) - -# [my-gatsby-site-v1.0.0-beta.17](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.16...my-gatsby-site-v1.0.0-beta.17) (2021-09-09) - - -### Bug Fixes - -* **blockcontainer:** disable SFBWrapper when not editing ([a171b96](https://github.com/snek-at/jaen/commit/a171b9610718864037f2a2fe5b4de44369886e2f)) - -# [my-gatsby-site-v1.0.0-beta.16](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.15...my-gatsby-site-v1.0.0-beta.16) (2021-09-09) - - -### Features - -* **choicefield:** add disable option for popover ([91a36ac](https://github.com/snek-at/jaen/commit/91a36ac01c4899d5a284b53c55e8e1416a125cbb)) -* introduce BlockContainer (StreamField replacement) ([e89c100](https://github.com/snek-at/jaen/commit/e89c1002b05ed33f69240b128d129ddbea5cb362)) - -# [my-gatsby-site-v1.0.0-beta.15](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.14...my-gatsby-site-v1.0.0-beta.15) (2021-09-08) - - -### Features - -* **chakraui:** enfore chakraui through jaen ([bd539de](https://github.com/snek-at/jaen/commit/bd539de1513f7656f5a7a5ce2f30c8c1628f8967)) - -# [my-gatsby-site-v1.0.0-beta.14](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.13...my-gatsby-site-v1.0.0-beta.14) (2021-09-08) - - -### Bug Fixes - -* **choicefield:** enable popover only on editing ([4ee9231](https://github.com/snek-at/jaen/commit/4ee923178ab30045d44f0d74ec85c8995bc02c52)) - - -### Features - -* remove initialValue form StreamField ([1c60e15](https://github.com/snek-at/jaen/commit/1c60e15311338ff2f060269ed81812a4ef2b655a)) - -# [my-gatsby-site-v1.0.0-beta.13](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.12...my-gatsby-site-v1.0.0-beta.13) (2021-09-08) - - -### Features - -* add ChoiceField ([115417b](https://github.com/snek-at/jaen/commit/115417b7a0fc9aca684df8ee068a87d58ce365bb)) - -# [my-gatsby-site-v1.0.0-beta.12](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.11...my-gatsby-site-v1.0.0-beta.12) (2021-09-07) - - -### Bug Fixes - -* **package.json:** align versions ([35e74c1](https://github.com/snek-at/jaen/commit/35e74c170d136f28676228e8726794aec45cb642)) -* **package.json:** update snekfinder version ([a764f35](https://github.com/snek-at/jaen/commit/a764f354abc83e43bf355c4efee57dc4c7e2b1d4)) -* add high zIndex to MainUI toggle button ([c180d92](https://github.com/snek-at/jaen/commit/c180d92678ce27e499bd9dcb10755de44732b3e1)) - - -### Features - -* jaenImage uses GatsbyImage now ([a28b99e](https://github.com/snek-at/jaen/commit/a28b99ec0e6bd83cb6359c4ff4783f6847e6a3a4)) -* streamField not includes build data ([b12ff24](https://github.com/snek-at/jaen/commit/b12ff24803c3c7e82971fbe252bb0c333fec469e)) - -# [my-gatsby-site-v1.0.0-beta.11](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.10...my-gatsby-site-v1.0.0-beta.11) (2021-09-06) - - -### Bug Fixes - -* **package.json:** align versions ([ca6fc14](https://github.com/snek-at/jaen/commit/ca6fc14c3ac34e6853d3c3d6afa894fe10dae445)) - -# [my-gatsby-site-v1.0.0-beta.10](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.9...my-gatsby-site-v1.0.0-beta.10) (2021-09-05) - - -### Bug Fixes - -* disable page updating on page change ([cbd2656](https://github.com/snek-at/jaen/commit/cbd2656579947d62e03efaf00212ee6533d2cb95)) -* **chakra:** reset css ([2d1d195](https://github.com/snek-at/jaen/commit/2d1d1956ae3c61f188696ea268625395cb1ffe37)) - -# [my-gatsby-site-v1.0.0-beta.9](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.8...my-gatsby-site-v1.0.0-beta.9) (2021-09-04) - - -### Bug Fixes - -* **indexfield:** fix page context ([74d6383](https://github.com/snek-at/jaen/commit/74d6383c5e52600dc64640e2e0e44c492110b758)) -* **package.json:** update versions ([8ce78ef](https://github.com/snek-at/jaen/commit/8ce78ef6a1b494f06428845f9470fe0717a030f3)) - -# [my-gatsby-site-v1.0.0-beta.8](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.7...my-gatsby-site-v1.0.0-beta.8) (2021-09-04) - - -### Features - -* add jaen-pages cli ([b2a9724](https://github.com/snek-at/jaen/commit/b2a972405f307e1682f5f72a23c1f026bbe9f2bb)) - -# my-gatsby-site-v1.0.0 (2021-09-04) - - -### Bug Fixes - -* page creaction and esm ([ab3bbda](https://github.com/schett-net/jaen/commit/ab3bbdabc37ae4ef14044bd6b29c4dfb80254362)) -* **package.json:** align monorepo package versions ([69661f7](https://github.com/schett-net/jaen/commit/69661f761edc4aa6c0839cb0a588dd328ec098a5)) -* remove transpiling ([9ec9b59](https://github.com/schett-net/jaen/commit/9ec9b59b69515bbdf3c47b77c9434ce2b38632f3)) -* **.babelrc:** add preset-react ([36a0f2c](https://github.com/schett-net/jaen/commit/36a0f2cba18b74a4a2a20e94bdc9d61f29c7089b)) -* **package.json:** update version ([fe2aa5a](https://github.com/schett-net/jaen/commit/fe2aa5a3c8a24533cf12497f1c96166cfd91b159)) -* enable transpiling ([037856a](https://github.com/schett-net/jaen/commit/037856a4bad791be351cc03b2afb29c65f9b8bff)) -* **package.json:** fix versions ([16c706c](https://github.com/schett-net/jaen/commit/16c706c328db52088ee1d521ab5c69c715221267)) - - -### Features - -* add gatsby publishing ([83d2704](https://github.com/schett-net/jaen/commit/83d270482c60a7783b408c7f954e8e148e51e741)) -* add jaen-pages migration workflow ([008918c](https://github.com/schett-net/jaen/commit/008918cc1c8d8ee88ad914f674b978ebc68e21c6)) -* add jaenPageContext ([2bf4da1](https://github.com/schett-net/jaen/commit/2bf4da1a154de2db83ebbec6fad5cfa3a758053b)) -* send publish request on button press ([75d5cfc](https://github.com/schett-net/jaen/commit/75d5cfcb35bcde7e7f3d455b44b9921e1dd2eefa)) - -# [my-gatsby-site-v1.0.0-beta.7](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.6...my-gatsby-site-v1.0.0-beta.7) (2021-09-02) - - -### Bug Fixes - -* page creaction and esm ([ab3bbda](https://github.com/snek-at/jaen/commit/ab3bbdabc37ae4ef14044bd6b29c4dfb80254362)) - -# [my-gatsby-site-v1.0.0-beta.6](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.5...my-gatsby-site-v1.0.0-beta.6) (2021-09-02) - - -### Bug Fixes - -* **package.json:** align monorepo package versions ([69661f7](https://github.com/snek-at/jaen/commit/69661f761edc4aa6c0839cb0a588dd328ec098a5)) - - -### Features - -* add gatsby publishing ([83d2704](https://github.com/snek-at/jaen/commit/83d270482c60a7783b408c7f954e8e148e51e741)) -* add jaen-pages migration workflow ([008918c](https://github.com/snek-at/jaen/commit/008918cc1c8d8ee88ad914f674b978ebc68e21c6)) -* add jaenPageContext ([2bf4da1](https://github.com/snek-at/jaen/commit/2bf4da1a154de2db83ebbec6fad5cfa3a758053b)) -* send publish request on button press ([75d5cfc](https://github.com/snek-at/jaen/commit/75d5cfcb35bcde7e7f3d455b44b9921e1dd2eefa)) - -# [my-gatsby-site-v1.0.0-beta.5](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.4...my-gatsby-site-v1.0.0-beta.5) (2021-09-01) - - -### Bug Fixes - -* remove transpiling ([9ec9b59](https://github.com/snek-at/jaen/commit/9ec9b59b69515bbdf3c47b77c9434ce2b38632f3)) - -# [my-gatsby-site-v1.0.0-beta.4](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.3...my-gatsby-site-v1.0.0-beta.4) (2021-08-31) - - -### Bug Fixes - -* **.babelrc:** add preset-react ([36a0f2c](https://github.com/snek-at/jaen/commit/36a0f2cba18b74a4a2a20e94bdc9d61f29c7089b)) - -# [my-gatsby-site-v1.0.0-beta.3](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.2...my-gatsby-site-v1.0.0-beta.3) (2021-08-31) - - -### Bug Fixes - -* **package.json:** update version ([fe2aa5a](https://github.com/snek-at/jaen/commit/fe2aa5a3c8a24533cf12497f1c96166cfd91b159)) - -# [my-gatsby-site-v1.0.0-beta.2](https://github.com/snek-at/jaen/compare/my-gatsby-site-v1.0.0-beta.1...my-gatsby-site-v1.0.0-beta.2) (2021-08-31) - - -### Bug Fixes - -* enable transpiling ([037856a](https://github.com/snek-at/jaen/commit/037856a4bad791be351cc03b2afb29c65f9b8bff)) diff --git a/examples/my-gatsby-site/README.md b/examples/my-gatsby-site/README.md index 2f81819..52a93fe 100644 --- a/examples/my-gatsby-site/README.md +++ b/examples/my-gatsby-site/README.md @@ -1,21 +1,21 @@

- + Gatsby

- Gatsby minimal starter + Gatsby Minimal TypeScript Starter

## πŸš€ Quick start 1. **Create a Gatsby site.** - Use the Gatsby CLI to create a new site, specifying the minimal starter. + Use the Gatsby CLI to create a new site, specifying the minimal TypeScript starter. ```shell - # create a new Gatsby site using the minimal starter - npm init gatsby + # create a new Gatsby site using the minimal TypeScript starter + npm init gatsby -- -ts ``` 2. **Start developing.** @@ -31,24 +31,19 @@ Your site is now running at http://localhost:8000! - Edit `src/pages/index.js` to see your site update in real-time! + Edit `src/pages/index.tsx` to see your site update in real-time! 4. **Learn more** - - [Documentation](https://www.gatsbyjs.com/docs/?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter) + - [Documentation](https://www.gatsbyjs.com/docs/?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter-ts) + - [Tutorials](https://www.gatsbyjs.com/docs/tutorial/?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter-ts) + - [Guides](https://www.gatsbyjs.com/docs/how-to/?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter-ts) + - [API Reference](https://www.gatsbyjs.com/docs/api-reference/?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter-ts) + - [Plugin Library](https://www.gatsbyjs.com/plugins?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter-ts) + - [Cheat Sheet](https://www.gatsbyjs.com/docs/cheat-sheet/?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter-ts) - - [Tutorials](https://www.gatsbyjs.com/tutorial/?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter) +## πŸš€ Quick start (Netlify) - - [Guides](https://www.gatsbyjs.com/tutorial/?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter) +Deploy this starter with one click on [Netlify](https://app.netlify.com/signup): - - [API Reference](https://www.gatsbyjs.com/docs/api-reference/?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter) - - - [Plugin Library](https://www.gatsbyjs.com/plugins?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter) - - - [Cheat Sheet](https://www.gatsbyjs.com/docs/cheat-sheet/?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter) - -## πŸš€ Quick start (Gatsby Cloud) - -Deploy this starter with one click on [Gatsby Cloud](https://www.gatsbyjs.com/cloud/): - -[Deploy to Gatsby Cloud](https://www.gatsbyjs.com/dashboard/deploynow?url=https://github.com/gatsbyjs/gatsby-starter-minimal) +[Deploy to Netlify](https://app.netlify.com/start/deploy?repository=https://github.com/gatsbyjs/gatsby-starter-minimal-ts) diff --git a/examples/my-gatsby-site/gatsby-browser.tsx b/examples/my-gatsby-site/gatsby-browser.tsx new file mode 100644 index 0000000..031a1ab --- /dev/null +++ b/examples/my-gatsby-site/gatsby-browser.tsx @@ -0,0 +1,16 @@ +import {GatsbyBrowser} from 'gatsby' +import {Box, Heading} from '@chakra-ui/react' + +// export const wrapPageElement: GatsbyBrowser['wrapPageElement'] = ({ +// element, +// props +// }) => { +// return ( +// +// +// My Site +// +// {element} +// +// ) +// } diff --git a/examples/my-gatsby-site/gatsby-config.js b/examples/my-gatsby-site/gatsby-config.js deleted file mode 100644 index b225fc4..0000000 --- a/examples/my-gatsby-site/gatsby-config.js +++ /dev/null @@ -1,21 +0,0 @@ -const path = require('path') - -const siteMetadata = require('./site-metadata') - -module.exports = { - siteMetadata, - plugins: [ - '@snek-at/jaen', - { - resolve: '@snek-at/jaen-pages', - options: { - templates: { - SamplePage: path.resolve('src/templates/SamplePage.tsx') - } - } - }, - { - resolve: 'gatsby-plugin-webpack-bundle-analyser-v2' - } - ] -} diff --git a/examples/my-gatsby-site/gatsby-config.ts b/examples/my-gatsby-site/gatsby-config.ts new file mode 100644 index 0000000..8e59245 --- /dev/null +++ b/examples/my-gatsby-site/gatsby-config.ts @@ -0,0 +1,54 @@ +import type {GatsbyConfig} from 'gatsby' + +require('dotenv').config() + +console.log('ENV', process.env.GATSBY_LENS_API_URL) + +const config: GatsbyConfig = { + siteMetadata: { + siteUrl: `https://www.yourdomain.tld` + }, + // More easily incorporate content into your pages through automatic TypeScript type generation and better GraphQL IntelliSense. + // If you use VSCode you can also use the GraphQL plugin + // Learn more at: https://gatsby.dev/graphql-typegen + graphqlTypegen: true, + flags: { + DEV_SSR: false + }, + plugins: [ + { + resolve: `gatsby-plugin-jaen`, + options: { + remote: { + repository: 'atsnek/jaen-starter' + }, + zitadel: { + organizationId: '252746033782587395', + clientId: '252746210698395651@services', + authority: 'https://accounts.cronit.io', + redirectUri: + process.env.NODE_ENV === 'production' + ? 'https://cronit.io' + : 'http://localhost:8000', + projectIds: [ + '252765861113233411', + '252899191242620931', + '260237544631828483' + ] + }, + googleAnalytics: { + trackingIds: ['G-M58K75M9PG'] + }, + sentry: { + org: 'cronit', + project: 'jaen-my-gatsby-site', + dsn: 'https://72993150e27f8a2a4b37fa1cfc3cdb60@sentry.cronit.io/2' + } + } + }, + `gatsby-jaen-mailpress` + // 'gatsby-plugin-webpack-bundle-analyser-v2' + ] +} + +export default config diff --git a/examples/my-gatsby-site/jaen-config.js b/examples/my-gatsby-site/jaen-config.js deleted file mode 100644 index 041d71e..0000000 --- a/examples/my-gatsby-site/jaen-config.js +++ /dev/null @@ -1,10 +0,0 @@ -module.exports = { - remote: 'snek-at/jaen-template', - initialHideUI: false, // optional hide UI on load - plugins: { - pages: { - resolve: require('@snek-at/jaen-pages/jaen-register'), - templates: [require('./src/templates/SamplePage.tsx')] - } - } -} diff --git a/examples/my-gatsby-site/jaen-data/patches.txt b/examples/my-gatsby-site/jaen-data/patches.txt new file mode 100644 index 0000000..70662b5 --- /dev/null +++ b/examples/my-gatsby-site/jaen-data/patches.txt @@ -0,0 +1 @@ +https://osg.snek.at/storage/BQACAgQAAx0Ed6zoewADeGYvY7NGEG9U46vPz2iux5jZ9klUAALmGAACM9R5Ua8ba8OQycAiLwQ \ No newline at end of file diff --git a/examples/my-gatsby-site/jaen-pages.json b/examples/my-gatsby-site/jaen-pages.json deleted file mode 100644 index 8a1b416..0000000 --- a/examples/my-gatsby-site/jaen-pages.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "pages": { - "SitePage /": { - "context": { - "fileUrl": "https://osg.snek.at/storage/BQACAgQAAxkDAANoYZqXG2kWlz1a5tKwxcso81HBKGAAAmELAAL6WdhQDo3zaRx4J8ciBA", - "createdAt": "2021-11-21T18:59:39.264Z" - }, - "migrations": [ - { - "fileUrl": "https://osg.snek.at/storage/BQACAgQAAxkDAANoYZqXG2kWlz1a5tKwxcso81HBKGAAAmELAAL6WdhQDo3zaRx4J8ciBA", - "createdAt": "2021-11-21T18:59:39.264Z" - } - ] - } - }, - "site": {}, - "snekFinder": { - "context": { - "createdAt": "2021-11-21T18:59:39.264Z", - "fileUrl": "https://osg.snek.at/storage/BQACAgQAAxkDAANlYZqV28a7097qmMjvd00iFx7M5tgAAl4LAAL6WdhQsW753yRCkaQiBA" - }, - "migrations": [ - { - "createdAt": "2021-11-21T18:59:39.264Z", - "fileUrl": "https://osg.snek.at/storage/BQACAgQAAxkDAANlYZqV28a7097qmMjvd00iFx7M5tgAAl4LAAL6WdhQsW753yRCkaQiBA" - } - ] - } -} \ No newline at end of file diff --git a/examples/my-gatsby-site/package.json b/examples/my-gatsby-site/package.json index 7201043..f075426 100644 --- a/examples/my-gatsby-site/package.json +++ b/examples/my-gatsby-site/package.json @@ -1,8 +1,8 @@ { "name": "my-gatsby-site", - "version": "1.1.0", + "version": "1.0.0", "private": true, - "description": "My Gatsby Site", + "description": "my-gatsby-site", "author": "Nico Schett", "keywords": [ "gatsby" @@ -10,25 +10,26 @@ "scripts": { "develop": "gatsby develop", "start": "gatsby develop", - "build": "gatsby build", + "build": "NODE_OPTIONS=--max-old-space-size=8192 gatsby build", "serve": "gatsby serve", - "clean": "gatsby clean" + "clean": "gatsby clean", + "typecheck": "tsc --noEmit" }, "dependencies": { - "@chakra-ui/gatsby-plugin": "^2.0.1", - "@chakra-ui/icons": "^1.0.15", - "@chakra-ui/react": "^1.6.7", - "@emotion/react": "^11", - "@emotion/styled": "^11", - "@snek-at/jaen": "^2.0.0", - "@snek-at/jaen-pages": "^2.0.0", - "framer-motion": "^4", - "gatsby": "^3.11.1", - "gatsby-plugin-emotion": "^6.11.0", - "react": "^17.0.1", - "react-dom": "^17.0.1" + "@atsnek/jaen": "^1.0.0-rc.1", + "@atsnek/jaen-fields-mdx": "^1.0.0-rc.1", + "@radix-ui/react-icons": "^1.3.0", + "@react-icons/all-files": "https://github.com/react-icons/react-icons/releases/download/v4.11.0/react-icons-all-files-4.11.0.tgz", + "gatsby": "^5.11.0", + "gatsby-plugin-jaen": "^1.0.0-rc.1", + "react": "^18.2.0", + "react-dom": "^18.2.0" }, "devDependencies": { - "gatsby-plugin-webpack-bundle-analyser-v2": "^1.1.24" + "@types/node": "^20.3.3", + "@types/react": "^18.2.14", + "@types/react-dom": "^18.2.6", + "gatsby-plugin-webpack-bundle-analyser-v2": "^1.1.31", + "typescript": "^5.1.6" } } diff --git a/examples/my-gatsby-site/site-metadata.json b/examples/my-gatsby-site/site-metadata.json deleted file mode 100644 index 44b3128..0000000 --- a/examples/my-gatsby-site/site-metadata.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "title": "snek site", - "description": " This is a blog theme. The description will be showed in SEO results on pages without their own descriptions.", - "siteUrl": "https://schettn-schett-net-jaen-45xwpww7fjg74-9000.githubpreview.dev", - "image": "https://ipfs.io/ipfs/QmcaK19wKwbvuLEZAb8k1dATCC3aQmQJyFkuWggcVGtDvg", - "author": { - "name": "Your Name", - "minibio": "This bio is shown at the bottom of each blog post. It supports custom HTML if you’re into that sort of thing." - }, - "organization": { - "name": "Example, Inc.", - "url": "https://example.com", - "logo": "https://lengstorf.com/android-chrome-512x512.png" - }, - "social": { - "twitter": "@jlengstorf", - "fbAppID": "" - }, - "categories": [ - { - "slug": "test", - "name": "Test Category" - } - ] -} \ No newline at end of file diff --git a/examples/my-gatsby-site/src/blocks/SampleBlock.tsx b/examples/my-gatsby-site/src/blocks/SampleBlock.tsx deleted file mode 100644 index 643282e..0000000 --- a/examples/my-gatsby-site/src/blocks/SampleBlock.tsx +++ /dev/null @@ -1,77 +0,0 @@ -import {Badge, HStack, VStack} from '@chakra-ui/layout' -import {Box} from '@chakra-ui/react' -import {fields} from '@snek-at/jaen-pages' -import type {JaenBlock} from '@snek-at/jaen-pages' - -const SampleBlock: JaenBlock = () => { - // return - - return ( - - {/* {property.imageAlt} */} - - - - - - New - - - - - - - - - - - - - - - - {/* {property.title} */} - - - - - {/* {property.formattedPrice} */} - - / wk - - - - - {/* {Array(5) - .fill("") - .map((_, i) => ( - - ))} */} - - {/* {property.reviewCount} reviews */} - - - - - ) -} - -SampleBlock.BlockName = 'SampleBlock' -SampleBlock.BlockDisplayName = 'SampleBlock' - -export default SampleBlock diff --git a/examples/my-gatsby-site/src/favicon.ico b/examples/my-gatsby-site/src/favicon.ico new file mode 100755 index 0000000..6b421ee --- /dev/null +++ b/examples/my-gatsby-site/src/favicon.ico @@ -0,0 +1,20 @@ + + + + + + + + + + + diff --git a/examples/my-gatsby-site/src/gatsby-plugin-jaen/components/Layout.tsx b/examples/my-gatsby-site/src/gatsby-plugin-jaen/components/Layout.tsx new file mode 100644 index 0000000..7eba9ae --- /dev/null +++ b/examples/my-gatsby-site/src/gatsby-plugin-jaen/components/Layout.tsx @@ -0,0 +1,37 @@ +import {LayoutProps, useWidget} from '@atsnek/jaen' +import {Box, Heading, HStack, Button} from '@chakra-ui/react' +import {useEffect} from 'react' + +const Layout: React.FC = ({children, pageProps}) => { + const [widget, setWidget] = useWidget('Header_Title', { + defaultData: 'Hello World' + }) + + return ( + + + + {widget.data} + + + + + + {children} + + ) +} + +export default Layout diff --git a/examples/my-gatsby-site/src/gatsby-plugin-jaen/components/Logo.tsx b/examples/my-gatsby-site/src/gatsby-plugin-jaen/components/Logo.tsx new file mode 100644 index 0000000..eab0808 --- /dev/null +++ b/examples/my-gatsby-site/src/gatsby-plugin-jaen/components/Logo.tsx @@ -0,0 +1,823 @@ +import {chakra} from '@chakra-ui/react' + +const Logo = () => { + return ( + + + ) +} + +export default Logo diff --git a/examples/my-gatsby-site/src/gatsby-plugin-jaen/components/Toolbar.tsx b/examples/my-gatsby-site/src/gatsby-plugin-jaen/components/Toolbar.tsx new file mode 100644 index 0000000..37034a7 --- /dev/null +++ b/examples/my-gatsby-site/src/gatsby-plugin-jaen/components/Toolbar.tsx @@ -0,0 +1,7 @@ +import {Button} from '@chakra-ui/react' + +export interface ToolbarProps {} + +export const Toolbar: React.FC = () => { + return +} diff --git a/examples/my-gatsby-site/src/gatsby-plugin-jaen/theme/theme.ts b/examples/my-gatsby-site/src/gatsby-plugin-jaen/theme/theme.ts new file mode 100644 index 0000000..54d6dcd --- /dev/null +++ b/examples/my-gatsby-site/src/gatsby-plugin-jaen/theme/theme.ts @@ -0,0 +1,29 @@ +import { + extendTheme, + ThemeConfig, + withDefaultColorScheme, + baseTheme +} from '@chakra-ui/react' + +export const colors = { + ...baseTheme.colors, + brand: { + ...baseTheme.colors.red, + 500: '#E3000F', + 600: '#E3000F' + } +} + +const theme = extendTheme( + { + colors, + styles: { + global: {} + } + }, + withDefaultColorScheme({ + colorScheme: 'brand' + }) +) + +export default theme diff --git a/examples/my-gatsby-site/src/pages/404.js b/examples/my-gatsby-site/src/pages/404.js deleted file mode 100644 index 053ae0e..0000000 --- a/examples/my-gatsby-site/src/pages/404.js +++ /dev/null @@ -1,54 +0,0 @@ -import * as React from "react" -import { Link } from "gatsby" - -// styles -const pageStyles = { - color: "#232129", - padding: "96px", - fontFamily: "-apple-system, Roboto, sans-serif, serif", -} -const headingStyles = { - marginTop: 0, - marginBottom: 64, - maxWidth: 320, -} - -const paragraphStyles = { - marginBottom: 48, -} -const codeStyles = { - color: "#8A6534", - padding: 4, - backgroundColor: "#FFF4DB", - fontSize: "1.25rem", - borderRadius: 4, -} - -// markup -const NotFoundPage = () => { - return ( -
- Not found -

Page not found

-

- Sorry{" "} - - πŸ˜” - {" "} - we couldn’t find what you were looking for. -
- {process.env.NODE_ENV === "development" ? ( - <> -
- Try creating a page in src/pages/. -
- - ) : null} -
- Go home. -

-
- ) -} - -export default NotFoundPage diff --git a/examples/my-gatsby-site/src/pages/404.tsx b/examples/my-gatsby-site/src/pages/404.tsx new file mode 100644 index 0000000..31ab8d7 --- /dev/null +++ b/examples/my-gatsby-site/src/pages/404.tsx @@ -0,0 +1,63 @@ +import * as React from 'react' +import {Link, HeadFC, PageProps} from 'gatsby' +import {PageConfig} from '@atsnek/jaen' +import {LightMode, GlobalStyle} from '@chakra-ui/react' + +const pageStyles = { + color: '#232129', + padding: '96px', + fontFamily: '-apple-system, Roboto, sans-serif, serif' +} +const headingStyles = { + marginTop: 0, + marginBottom: 64, + maxWidth: 320 +} + +const paragraphStyles = { + marginBottom: 48 +} +const codeStyles = { + color: '#8A6534', + padding: 4, + backgroundColor: '#FFF4DB', + fontSize: '1.25rem', + borderRadius: 4 +} + +const NotFoundPage: React.FC = () => { + React.useEffect(() => { + alert('404') + }, []) + + return ( + + +
+

Page not found

+

+ Sorry πŸ˜”, we couldn’t find what you were looking for. +
+ {process.env.NODE_ENV === 'development' ? ( + <> +
+ Try creating a page in src/pages/. +
+ + ) : null} +
+ Go home. +

+
+
+ ) +} + +export default NotFoundPage + +export {Head} from '@atsnek/jaen' + +export const pageConfig: PageConfig = { + label: 'Oops! Page not found', + childTemplates: ['BlogPage'] +} diff --git a/examples/my-gatsby-site/src/pages/auth.tsx b/examples/my-gatsby-site/src/pages/auth.tsx new file mode 100644 index 0000000..b9ad0c6 --- /dev/null +++ b/examples/my-gatsby-site/src/pages/auth.tsx @@ -0,0 +1,39 @@ +// src/App.jsx +import React from 'react' +import {useAuth} from 'react-oidc-context' + +function App() { + const auth = useAuth() + + switch (auth.activeNavigator) { + case 'signinSilent': + return
Signing you in...
+ case 'signoutRedirect': + return
Signing you out...
+ } + + if (auth.isLoading) { + return
Loading...
+ } + + if (auth.error) { + return
Oops... {auth.error.message}
+ } + + if (auth.isAuthenticated) { + return ( +
+ Hello {auth.user?.profile.sub}{' '} + +

+      
+ ) + } + + return +} + +export default App diff --git a/examples/my-gatsby-site/src/pages/contact.tsx b/examples/my-gatsby-site/src/pages/contact.tsx new file mode 100644 index 0000000..99df281 --- /dev/null +++ b/examples/my-gatsby-site/src/pages/contact.tsx @@ -0,0 +1,151 @@ +import {PageConfig, PageProps, useNotificationsContext} from '@atsnek/jaen' + +import { + Button, + Checkbox, + FormControl, + FormErrorMessage, + // FormErrorMessage, + FormLabel, + HStack, + Heading, + Input, + Stack, + Text, + Textarea, + VStack +} from '@chakra-ui/react' +import {FC} from 'react' +import {SubmitHandler, useForm} from 'react-hook-form' + +import {sq} from 'gatsby-jaen-mailpress' + +type FormValues = { + name: string + email: string + message: string + agreement: boolean +} + +/** + * Content for the contact page. + */ +const ContactContent: FC = () => { + const {toast} = useNotificationsContext() + + const {register, handleSubmit, formState} = useForm() + const {errors, isSubmitting, isValid} = formState + + const onSubmit: SubmitHandler = async data => { + const [_, errors] = await sq.mutate(m => + m.sendTemplateMail({ + envelope: { + to: [data.email], + replyTo: data.email + }, + id: '77c7adf2-1b1b-4c1a-8d99-d44366764814', + values: { + name: data.name, + message: data.message + } + }) + ) + + if (errors) { + toast({ + title: 'Error', + description: 'Something went wrong while sending your message', + status: 'error' + }) + } else { + toast({ + title: 'Success', + description: 'Your message has been sent', + status: 'success' + }) + } + } + + //!Bug: The default focusBorderColor of all inputs is different from the theme (some strange purple color) + return ( + + + Contact Us + + + We are here to help you with any questions you may have. + +
+ + + + Name + + + + Email + + + + + Message +