Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: qld-gov-au/formio
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v1.0.4
Choose a base ref
...
head repository: qld-gov-au/formio
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: main
Choose a head ref
Loading
Showing with 60,593 additions and 50,814 deletions.
  1. +54 −0 .chglog/CHANGELOG.tpl.md
  2. +18 −0 .chglog/config.yml
  3. +0 −7 .eslintignore
  4. +30 −5 .eslintrc → .eslintrc.cjs
  5. +17 −0 .github/dependabot.yml
  6. +110 −0 .github/workflows/Storybook-library-update.yml
  7. +74 −36 .github/workflows/compile.js.yml
  8. +100 −0 .github/workflows/formioGridLibUpdate.js.yml
  9. +100 −0 .github/workflows/formioJSLibUpdate.js.yml
  10. +100 −0 .github/workflows/formioLibUpdate.js.yml
  11. +75 −18 .github/workflows/storybook-deploy.js.yml
  12. +37 −0 .github/workflows/updateChangeLog.yml
  13. +6 −0 .github/workspace/formiojs/npm
  14. +6 −0 .github/workspace/formiojs/npx
  15. +579 −0 .github/workspace/formiojs/package-lock.json
  16. +37 −0 .github/workspace/formiojs/package.json
  17. +61 −0 .github/workspace/formiojs/pom.xml
  18. +6 −0 .github/workspace/grid/npm
  19. +6 −0 .github/workspace/grid/npx
  20. +360 −0 .github/workspace/grid/package-lock.json
  21. +36 −0 .github/workspace/grid/package.json
  22. +61 −0 .github/workspace/grid/pom.xml
  23. +6 −0 .github/workspace/prem/npm
  24. +6 −0 .github/workspace/prem/npx
  25. +1,392 −0 .github/workspace/prem/package-lock.json
  26. +38 −0 .github/workspace/prem/package.json
  27. +61 −0 .github/workspace/prem/pom.xml
  28. +5 −0 .gitignore
  29. +4 −0 .npmrc
  30. +50 −11 .storybook/main.js
  31. +0 −1 .storybook/preview-head.html
  32. +28 −14 .storybook/preview.js
  33. 0 .storybook/static/.nojekyll
  34. +40 −8 { → .webpack}/webpack.config.js
  35. +726 −0 CHANGELOG.md
  36. +157 −10 README.md
  37. +4 −1 jest.config.js
  38. +7 −0 lib/.well-known/sector-identifiers.json
  39. +22 −0 lib/changelog.md
  40. BIN lib/fonts/FontAwesome.otf
  41. BIN lib/fonts/fontawesome-webfont.eot
  42. +2,671 −0 lib/fonts/fontawesome-webfont.svg
  43. BIN lib/fonts/fontawesome-webfont.ttf
  44. BIN lib/fonts/fontawesome-webfont.woff
  45. BIN lib/fonts/fontawesome-webfont.woff2
  46. +6,287 −0 lib/formio.changelog.md
  47. +4,626 −0 lib/formio.full.css
  48. +2,600 −1,024 lib/formio.full.js
  49. +2 −2 lib/formio.full.min.css
  50. +1 −1 lib/formio.full.min.js
  51. +58 −0 lib/formio.full.min.js.LICENSE.txt
  52. +7 −0 lib/grid/formio.grid.changelog.md
  53. +298 −0 lib/grid/formio.grid.css
  54. +1,711 −0 lib/grid/formio.grid.js
  55. +1 −0 lib/grid/formio.grid.min.css
  56. +2 −0 lib/grid/formio.grid.min.js
  57. +8 −0 lib/grid/formio.grid.min.js.LICENSE.txt
  58. +767 −0 lib/premium.changelog.md
  59. +216 −53 lib/premium.css
  60. +1 −0 lib/premium.css.map
  61. +1,445 −0 lib/premium.js
  62. +2 −30 lib/premium.min.js
  63. +15 −0 lib/premium.min.js.LICENSE.txt
  64. +232 −0 lib/providers.js
  65. +2 −0 lib/providers.min.js
  66. +15 −0 lib/providers.min.js.LICENSE.txt
  67. +15,933 −0 lib/rulesEngine.js
  68. +2 −0 lib/rulesEngine.min.js
  69. +66 −0 lib/rulesEngine.min.js.LICENSE.txt
  70. +8 −3 lib/versions.txt
  71. +6 −0 npm
  72. +6 −0 npx
  73. +13,875 −48,167 package-lock.json
  74. +56 −42 package.json
  75. +4 −4 pom.xml
  76. +34 −0 src/components/BoilerplateButton/BoilerplateButton.form.js
  77. +63 −0 src/components/BoilerplateButton/BoilerplateButton.js
  78. +32 −0 src/components/BoilerplateButton/BoilerplateButton.mdx
  79. +47 −0 src/components/BoilerplateButton/BoilerplateButton.stories.js
  80. +41 −0 src/components/BoilerplateButton/BoilerplateButton.test.js
  81. +145 −0 src/components/BoilerplateButton/editFrom/BoilerplateButton.edit.display.js
  82. +1 −0 src/components/BoilerplateButton/index.js
  83. +39 −0 src/components/Button/sass/button.swe.scss
  84. +0 −28 src/components/CustomHeader/CustomHeader.js
  85. +0 −55 src/components/CustomHeader/CustomHeader.stories.mdx
  86. +0 −24 src/components/CustomHeader/CustomHeader.test.js
  87. +0 −1 src/components/CustomHeader/index.js
  88. +0 −27 src/components/CustomTextfield/CustomTextfield.js
  89. +0 −67 src/components/CustomTextfield/CustomTextfield.stories.mdx
  90. +0 −69 src/components/CustomTextfield/CustomTextfield.test.js
  91. +0 −1 src/components/CustomTextfield/index.js
  92. +15 −0 src/components/DataGrid/sass/datagrid.swe.scss
  93. +5 −0 src/components/Dropdown/sass/dropdown.swe.scss
  94. +33 −0 src/components/PdfSubmitButton/PdfSubmitButton.form.js
  95. +125 −0 src/components/PdfSubmitButton/PdfSubmitButton.js
  96. +39 −0 src/components/PdfSubmitButton/PdfSubmitButton.mdx
  97. +159 −0 src/components/PdfSubmitButton/PdfSubmitButton.stories.js
  98. +191 −0 src/components/PdfSubmitButton/editFrom/PdfSubmitButton.edit.display.js
  99. +1 −0 src/components/PdfSubmitButton/index.js
  100. +1 −1 src/components/PlsPlusAddress/PlsPlusAddress.form.js
  101. +251 −247 src/components/PlsPlusAddress/PlsPlusAddress.js
  102. +28 −0 src/components/PlsPlusAddress/PlsPlusAddress.mdx
  103. +69 −0 src/components/PlsPlusAddress/PlsPlusAddress.stories.js
  104. +0 −86 src/components/PlsPlusAddress/PlsPlusAddress.stories.mdx
  105. +264 −48 src/components/PlsPlusAddress/PlsPlusAddress.test.js
  106. +1 −1 src/components/PlsPlusAddress/editForm/PlsPlusAddress.edit.provider.js
  107. +20 −24 src/components/PlsPlusAddress/fixtures/formData.js
  108. +25 −0 src/components/PlsPlusAddress/sass/plsPlusAddress.swe.scss
  109. +21 −0 src/components/Radio/Radio.mdx
  110. +69 −0 src/components/Radio/Radio.stories.js
  111. +9 −0 src/components/Radio/sass/radio.ds.scss
  112. +12 −0 src/components/Radio/sass/radio.swe.scss
  113. +165 −0 src/components/SSOButton/SSOButton.js
  114. +1 −0 src/components/SSOButton/index.js
  115. +17 −0 src/components/googleLocation/GoogleLocation.form.js
  116. +184 −0 src/components/googleLocation/GoogleLocation.js
  117. +23 −0 src/components/googleLocation/GoogleLocation.mdx
  118. +79 −0 src/components/googleLocation/GoogleLocation.stories.js
  119. +14 −0 src/components/googleLocation/GoogleLocation.test.js.disabled
  120. +31 −0 src/components/googleLocation/editForm/Location.edit.map.js
  121. +32 −0 src/components/googleLocation/fixtures/comp1.js
  122. +1 −0 src/components/googleLocation/fixtures/index.js
  123. +1 −0 src/components/googleLocation/index.js
  124. +11 −0 src/components/index.des.js
  125. +11 −0 src/components/index.dev.js
  126. +9 −2 src/components/index.js
  127. +17 −0 src/components/openStreetMapLocation/OpenStreetMapLocation.form.js
  128. +213 −0 src/components/openStreetMapLocation/OpenStreetMapLocation.js
  129. +25 −0 src/components/openStreetMapLocation/OpenStreetMapLocation.mdx
  130. +132 −0 src/components/openStreetMapLocation/OpenStreetMapLocation.stories.js
  131. +29 −0 src/components/openStreetMapLocation/editForm/OpenStreetMapLocation.edit.map.js
  132. +1 −0 src/components/openStreetMapLocation/index.js
  133. +39 −13 src/config/createForm.controller.js
  134. +1 −0 src/config/createForm.options.js
  135. +24 −0 src/examples/DownloadPdf/DownloadPdf.code.js
  136. +20 −0 src/examples/DownloadPdf/DownloadPdf.js
  137. +22 −0 src/examples/DownloadPdf/DownloadPdf.mdx
  138. +34 −0 src/examples/DownloadPdf/DownloadPdf.stories.js
  139. +24 −0 src/examples/DownloadPdf/DownloadPdfWizard.code.js
  140. +20 −0 src/examples/DownloadPdf/DownloadPdfWizard.js
  141. +6 −7 src/examples/SimpleWizard/SimpleWizard.code.js
  142. +44 −4 src/examples/SimpleWizard/SimpleWizard.js
  143. +14 −0 src/examples/SimpleWizard/SimpleWizard.mdx
  144. +19 −0 src/examples/SimpleWizard/SimpleWizard.stories.js
  145. +0 −26 src/examples/SimpleWizard/SimpleWizard.stories.mdx
  146. +82 −0 src/examples/SimpleWizard/SimpleWizard.test.js
  147. +12 −17 src/examples/SingleSignOn/{SingleSignOn.stories.mdx → SingleSignOn.mdx}
  148. +38 −0 src/examples/SingleSignOn/SingleSignOn.stories.js
  149. +0 −1 src/examples/SingleSignOn/index.js
  150. +24 −0 src/examples/SingleSignOn/stories/SSOUnauth.code.js
  151. +22 −0 src/examples/SingleSignOn/stories/SSOUnauth.js
  152. +5 −6 src/examples/SingleSignOn/{ → stories}/SingleSignOn.code.js
  153. +59 −39 src/examples/SingleSignOn/{ → stories}/SingleSignOn.js
  154. +74 −34 src/helpers/FormioLoader/FormioLoader.js
  155. +79 −105 src/helpers/FormioLoader/{FormioLoader.stories.mdx → FormioLoader.mdx}
  156. +102 −0 src/helpers/FormioLoader/FormioLoader.stories.js
  157. +52 −43 src/helpers/FormioLoader/FormioLoader.test.js
  158. +2 −2 src/helpers/FormioLoader/stories/CustomController/CustomController.code.js
  159. +2 −2 src/helpers/FormioLoader/stories/CustomOptions/CustomOptions.code.js
  160. +2 −2 src/helpers/FormioLoader/stories/InitFormio/InitFormio.code.js
  161. +2 −2 src/helpers/FormioLoader/stories/InitFormioInstance/InitFormioInstance.code.js
  162. +22 −15 src/helpers/FormioScript/FormioScript.js
  163. +56 −48 src/helpers/FormioScript/{FormioScript.stories.mdx → FormioScript.mdx}
  164. +4 −5 src/helpers/FormioScript/index.dev.js
  165. +4 −41 src/helpers/FormioScript/index.gitbridge.js
  166. +15 −13 src/helpers/FormioScript/index.prod.js
  167. +4 −5 src/helpers/FormioScript/index.staging.js
  168. +4 −5 src/helpers/FormioScript/index.testing.js
  169. +15 −0 src/index.des.js
  170. +1 −2 src/index.js
  171. +4 −4 src/providers/address/PlsPlusAddressProvider.js
  172. +4 −0 src/sass/formio.form.ds.scss
  173. +7 −0 src/sass/formio.form.stories.scss
  174. +8 −0 src/sass/formio.form.swe.scss
  175. +30 −0 src/stories/BestPratices.mdx
  176. +57 −0 src/stories/How.mdx
  177. +30 −0 src/stories/Welcome.mdx
  178. +0 −39 src/stories/Welcome.stories.mdx
  179. +324 −0 src/stories/WhyAndWhen.mdx
  180. +115 −0 src/stories/assets/Grab my IP (grabMyIp)-Resource.json
  181. +466 −0 src/stories/assets/Grab my IP example (grabMyIpExample)-Form.json
  182. BIN src/stories/assets/formioSettings.png
  183. +25 −0 src/templates/bootstrap/boilerplateButton/form.ejs
  184. +3 −0 src/templates/bootstrap/boilerplateButton/html.ejs
  185. +10 −0 src/templates/bootstrap/boilerplateButton/index.js
  186. +1 −0 src/templates/bootstrap/googleMap/form.ejs
  187. +3 −0 src/templates/bootstrap/googleMap/index.js
  188. +3 −0 src/templates/bootstrap/index.des.js
  189. +5 −0 src/templates/bootstrap/index.dev.js
  190. +4 −0 src/templates/bootstrap/index.js
  191. +1 −0 src/templates/bootstrap/leafletMap/form.ejs
  192. +3 −0 src/templates/bootstrap/leafletMap/index.js
  193. +1 −1 src/templates/bootstrap/plsPlusAddress/form.ejs
  194. +3 −0 src/templates/index.dev.js
  195. +1 −1 src/templates/index.js
  196. +120 −105 src/test/fixtures/plsPlusAddress.js
  197. +299 −105 src/test/fixtures/simpleWizard.js
  198. +3 −3 src/test/setupTest.js
  199. +24 −0 src/utils/delegateSelector.js
  200. +1 −1 src/utils/indent.js
  201. +7 −0 src/utils/jestLoader.js
  202. +4 −0 src/utils/pushDataLayer.js
54 changes: 54 additions & 0 deletions .chglog/CHANGELOG.tpl.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
{{ if .Versions -}}
<a name="unreleased"></a>
## [Unreleased]

{{ if .Unreleased.CommitGroups -}}
{{ range .Unreleased.CommitGroups -}}
{{ range .Commits -}}
- {{ .Header }}
{{ end }}
{{ end -}}
{{ end -}}
{{ end -}}

{{ range .Versions }}
<a name="{{ .Tag.Name }}"></a>
## {{ if .Tag.Previous }}[{{ .Tag.Name }}]{{ else }}{{ .Tag.Name }}{{ end }} - {{ datetime "2006-01-02" .Tag.Date }}
{{ range .CommitGroups -}}
{{ range .Commits -}}
- {{ .Header }}
{{ end }}
{{ end -}}

{{- if .RevertCommits -}}
### Reverts
{{ range .RevertCommits -}}
- {{ .Revert.Header }}
{{ end }}
{{ end -}}

{{- if .MergeCommits -}}
### Pull Requests
{{ range .MergeCommits -}}
- {{ .Header }}
{{ end }}
{{ end -}}

{{- if .NoteGroups -}}
{{ range .NoteGroups -}}
### {{ .Title }}
{{ range .Notes }}
{{ .Body }}
{{ end }}
{{ end -}}
{{ end -}}
{{ end -}}

{{- if .Versions }}
[Unreleased]: {{ .Info.RepositoryURL }}/compare/{{ $latest := index .Versions 0 }}{{ $latest.Tag.Name }}...HEAD
{{ range .Versions -}}
{{ if .Tag.Previous -}}
[{{ .Tag.Name }}]: {{ $.Info.RepositoryURL }}/compare/{{ .Tag.Previous.Name }}...{{ .Tag.Name }}
{{ end -}}
{{ end -}}
{{ end -}}
18 changes: 18 additions & 0 deletions .chglog/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
style: github
template: CHANGELOG.tpl.md
info:
title: CHANGELOG
repository_url: https://github.com/qld-gov-au/formio
options:
commits:
# filters:
# Type: []
commit_groups:
# title_maps: []
header:
pattern: "^(.*)$"
pattern_maps:
- Subject
notes:
keywords:
- BREAKING CHANGE
7 changes: 0 additions & 7 deletions .eslintignore

This file was deleted.

35 changes: 30 additions & 5 deletions .eslintrc → .eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -1,6 +1,26 @@
{
module.exports = {
"ignorePatterns": [
"node_modules/",
"dist/",
"builder/",
"!.storybook/",
"storybook-static/",
"binary-repo/",
"lib/"

],
"parser": "@babel/eslint-parser",
"extends": ["airbnb", "plugin:json/recommended", "plugin:jest/recommended", "plugin:prettier/recommended"],
"extends": [
"airbnb",
"plugin:json/recommended",
"plugin:jest/recommended",
"plugin:prettier/recommended",
"plugin:storybook/recommended",
"plugin:mdx/recommended"
],
"settings": {
"mdx/code-blocks": true,
},
"rules": {
"prettier/prettier": ["error"],
"import/no-extraneous-dependencies": [
@@ -10,11 +30,16 @@
}
],
"react/jsx-filename-extension": [2, { "extensions": [".js", ".jsx", ".ts", ".tsx", ".mdx"] }],
"import/prefer-default-export": "off",
"no-console": ["warn", { "allow": ["warn", "error", "info", "debug"] }],
"no-param-reassign": ["error", { "props": false }],
"class-methods-use-this": 0,
"import/no-webpack-loader-syntax": "off"
"jsx-a11y/control-has-associated-label": "warn",

"import/prefer-default-export": "off",
"import/no-webpack-loader-syntax": "off",
"jsx-a11y/anchor-has-content": "off",
"jsx-a11y/heading-has-content": "off",
"react/self-closing-comp": "off",
},
"env": {
"jest/globals": true
@@ -38,4 +63,4 @@
}
}
]
}
}
17 changes: 17 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
version: 2
updates:
- package-ecosystem: npm
directory: "/"
target-branch: "develop"
schedule:
interval: daily
time: "19:00"
groups:
storybook:
patterns:
- "@storybook/*"
- storybook
open-pull-requests-limit: 10
reviewers:
- duttonw
- qld-gov-au/qld-online-dev-team
110 changes: 110 additions & 0 deletions .github/workflows/Storybook-library-update.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,110 @@
name: Update Storybook package.json items
on:
#schedule:
# * is a special character in YAMLso you have to quote this string
# - cron: '0 1 * * *'
workflow_dispatch:
inputs:
description:
description: 'Manual run of update Libs'
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: write #Work with the contents of the repository. For example, contents: read permits an action to list the commits, and contents: write allows the action to create a release.
#pages: write #Work with GitHub Pages. For example, pages: write permits an action to request a GitHub Pages build.
actions: read #Work with GitHub Actions. For example, actions: write permits an action to cancel a workflow run.
id-token: write #Fetch an OpenID Connect (OIDC) token. This requires id-token: write.
pull-requests: write #Work with pull requests. For example, pull-requests: write permits an action to add a label to a pull request.

jobs:
updateLibs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
ref: "develop"

- name: Cache node modules
id: cache-npm
uses: actions/cache@v3
env:
cache-name: cache-node-modules
with:
# npm cache files are stored in `~/.npm` on Linux/macOS
path: ~/.npm
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- if: ${{ steps.cache-npm.outputs.cache-hit != 'true' }}
name: List the state of node modules
continue-on-error: true
run: npm list

# run script in prem, extract to lib, update versions.txt on each file
- name: list folder
run: |
pwd
ls -ltr
- name: Use Node.js
uses: actions/setup-node@v3
with:
node-version: 20
cache: 'npm'

- name: Install
run: | # Install packages
npm install --prefer-offline --no-audit --ignore-scripts
env:
NODE_AUTH_TOKEN: ${{ secrets.NEXUSREADONLY2NPMTOKEN }}

# `npm rebuild` will run all those post-install scripts for us.
- name: rebuild and prepare
run: npm rebuild && npm run prepare --if-present

- name: List versions
run: | # List versions
npm view storybook versions
- name: What changed
run: |
export outdated="`npm outdated --parsable `"
echo '### Outdated' >> $GITHUB_STEP_SUMMARY
echo "$outdated" >> $GITHUB_STEP_SUMMARY
echo '' >> $GITHUB_STEP_SUMMARY
echo 'OUTDATED_LIST<<EOF' >> $GITHUB_OUTPUT
echo "$outdated" >> $GITHUB_OUTPUT
echo 'EOF' >> $GITHUB_OUTPUT
echo "OUTDATED_VERSION<<EOF" >> $GITHUB_OUTPUT
npm outdated --parsable|grep ^storybook|awk '{ print $4 }' >> $GITHUB_OUTPUT
echo 'EOF' >> $GITHUB_OUTPUT
echo $outdated|grep ^storybook|awk '{ print $4 }'
id: what-changed-data

- name: Update package.json ${{ steps.what-changed-data.outputs.OUTDATED_VERSION }}
run: | # Update storybook
npx storybook@latest upgrade -y
- name: Install latest
run: | # Install packages https://github.com/actions/setup-node/blob/main/docs/advanced-usage.md#use-private-packages
npm install --no-audit --ignore-scripts
# `npm rebuild` will run all those post-install scripts for us.
- name: rebuild and prepare
run: npm rebuild && npm run prepare --if-present

# todo work out how to extract 'outdated' to be commit message
- name: Create Pull Request
uses: peter-evans/create-pull-request@v4
with:
commit-message: "update storybook js libraries \r\n ${{ steps.what-changed-data.outputs.OUTDATED_LIST }}"
title: "update storybook ${{ steps.what-changed-data.outputs.OUTDATED_VERSION }}"
body: "update storybook \r\n ### Please Manually close pull requests and immediately reopen them. This will enable on: pull_request workflows to run and be added as checks. \r\n ${{ steps.what-changed-data.outputs.OUTDATED_LIST }}"
branch: "update-storybook-libraries-${{ steps.what-changed-data.outputs.OUTDATED_VERSION }}"
base: develop
Loading