@aws-amplify/ui-svelte 0.0.0-next-c8114c5-20220105200507

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (57) hide show
  1. package/.eslintrc.cjs +20 -0
  2. package/.turbo/turbo-build.log +135 -0
  3. package/CHANGELOG.md +15 -0
  4. package/README.md +38 -0
  5. package/dist/README.md +38 -0
  6. package/dist/components/Authenticator.svelte +43 -0
  7. package/dist/components/Authenticator.svelte.d.ts +22 -0
  8. package/dist/components/SignIn.svelte +69 -0
  9. package/dist/components/SignIn.svelte.d.ts +14 -0
  10. package/dist/components/UserNameAlias.svelte +29 -0
  11. package/dist/components/UserNameAlias.svelte.d.ts +19 -0
  12. package/dist/components/authStore.d.ts +20 -0
  13. package/dist/components/authStore.js +100 -0
  14. package/dist/components/primitives/AmplifyButton.svelte +23 -0
  15. package/dist/components/primitives/AmplifyButton.svelte.d.ts +25 -0
  16. package/dist/components/primitives/AmplifyError.svelte +46 -0
  17. package/dist/components/primitives/AmplifyError.svelte.d.ts +16 -0
  18. package/dist/components/primitives/AmplifyFormField.svelte +121 -0
  19. package/dist/components/primitives/AmplifyFormField.svelte.d.ts +25 -0
  20. package/dist/components/primitives/AmplifyFormSelect.svelte +38 -0
  21. package/dist/components/primitives/AmplifyFormSelect.svelte.d.ts +20 -0
  22. package/dist/components/primitives/AmplifyPasswordField.svelte +75 -0
  23. package/dist/components/primitives/AmplifyPasswordField.svelte.d.ts +26 -0
  24. package/dist/components/primitives/AmplifyPhoneNumberField.svelte +50 -0
  25. package/dist/components/primitives/AmplifyPhoneNumberField.svelte.d.ts +27 -0
  26. package/dist/components/primitives/AmplifyTabItem.svelte +0 -0
  27. package/dist/components/primitives/AmplifyTabItem.svelte.d.ts +19 -0
  28. package/dist/components/primitives/AmplifyTabs.svelte +50 -0
  29. package/dist/components/primitives/AmplifyTabs.svelte.d.ts +14 -0
  30. package/dist/components/primitives/AmplifyTextField.svelte +31 -0
  31. package/dist/components/primitives/AmplifyTextField.svelte.d.ts +28 -0
  32. package/dist/index.d.ts +3 -0
  33. package/dist/index.js +3 -0
  34. package/dist/package.json +60 -0
  35. package/dist/styles.css +1 -0
  36. package/package.json +57 -0
  37. package/src/app.html +21 -0
  38. package/src/global.d.ts +1 -0
  39. package/src/lib/components/Authenticator.svelte +52 -0
  40. package/src/lib/components/SignIn.svelte +79 -0
  41. package/src/lib/components/UserNameAlias.svelte +32 -0
  42. package/src/lib/components/authStore.ts +138 -0
  43. package/src/lib/components/primitives/AmplifyButton.svelte +25 -0
  44. package/src/lib/components/primitives/AmplifyError.svelte +48 -0
  45. package/src/lib/components/primitives/AmplifyFormField.svelte +146 -0
  46. package/src/lib/components/primitives/AmplifyFormSelect.svelte +39 -0
  47. package/src/lib/components/primitives/AmplifyPasswordField.svelte +78 -0
  48. package/src/lib/components/primitives/AmplifyPhoneNumberField.svelte +52 -0
  49. package/src/lib/components/primitives/AmplifyTabItem.svelte +0 -0
  50. package/src/lib/components/primitives/AmplifyTabs.svelte +52 -0
  51. package/src/lib/components/primitives/AmplifyTextField.svelte +33 -0
  52. package/src/lib/index.ts +4 -0
  53. package/src/lib/styles.css +1 -0
  54. package/src/routes/index.svelte +8 -0
  55. package/static/favicon.png +0 -0
  56. package/svelte.config.js +41 -0
  57. package/tsconfig.json +31 -0
package/.eslintrc.cjs ADDED
@@ -0,0 +1,20 @@
1
+ module.exports = {
2
+ root: true,
3
+ parser: '@typescript-eslint/parser',
4
+ extends: ['eslint:recommended', 'plugin:@typescript-eslint/recommended', 'prettier'],
5
+ plugins: ['svelte3', '@typescript-eslint'],
6
+ ignorePatterns: ['*.cjs'],
7
+ overrides: [{ files: ['*.svelte'], processor: 'svelte3/svelte3' }],
8
+ settings: {
9
+ 'svelte3/typescript': () => require('typescript')
10
+ },
11
+ parserOptions: {
12
+ sourceType: 'module',
13
+ ecmaVersion: 2020
14
+ },
15
+ env: {
16
+ browser: true,
17
+ es2017: true,
18
+ node: true
19
+ }
20
+ };
@@ -0,0 +1,135 @@
1
+ @aws-amplify/ui-svelte:build: cache hit, replaying output f1245cbc36765cdf
2
+ @aws-amplify/ui-svelte:build: warning package.json: No license field
3
+ @aws-amplify/ui-svelte:build: $ svelte-kit build
4
+ @aws-amplify/ui-svelte:build: vite v2.7.10 building for production...
5
+ @aws-amplify/ui-svelte:build: transforming...
6
+ @aws-amplify/ui-svelte:build:
7
+ @aws-amplify/ui-svelte:build: warn - Tailwind is not purging unused styles because no template paths have been provided.
8
+ @aws-amplify/ui-svelte:build: warn - If you have manually configured PurgeCSS outside of Tailwind or are deliberately not removing unused styles, set `purge: false` in your Tailwind config file to silence this warning.
9
+ @aws-amplify/ui-svelte:build: warn - https://tailwindcss.com/docs/controlling-file-size/#removing-unused-css
10
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-amplify/core/node_modules/tslib/package.json.
11
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
12
+ @aws-amplify/ui-svelte:build: (Use `node --trace-deprecation ...` to show where the warning was created)
13
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/tslib/package.json.
14
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
15
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/credential-provider-cognito-identity/node_modules/tslib/package.json.
16
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
17
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/util-create-request/node_modules/tslib/package.json.
18
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
19
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/middleware-content-length/node_modules/tslib/package.json.
20
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
21
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/middleware-host-header/node_modules/tslib/package.json.
22
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
23
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/querystring-builder/node_modules/tslib/package.json.
24
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
25
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/s3-request-presigner/node_modules/tslib/package.json.
26
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
27
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/config-resolver/node_modules/tslib/package.json.
28
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
29
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/middleware-logger/node_modules/tslib/package.json.
30
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
31
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/middleware-retry/node_modules/tslib/package.json.
32
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
33
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/middleware-signing/node_modules/tslib/package.json.
34
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
35
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/middleware-user-agent/node_modules/tslib/package.json.
36
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
37
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/smithy-client/node_modules/tslib/package.json.
38
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
39
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-crypto/sha256-browser/node_modules/tslib/package.json.
40
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
41
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/util-user-agent-browser/node_modules/tslib/package.json.
42
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
43
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/middleware-serde/node_modules/tslib/package.json.
44
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
45
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/middleware-expect-continue/node_modules/tslib/package.json.
46
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
47
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/middleware-ssec/node_modules/tslib/package.json.
48
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
49
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/middleware-location-constraint/node_modules/tslib/package.json.
50
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
51
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/protocol-http/node_modules/tslib/package.json.
52
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
53
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/eventstream-marshaller/node_modules/tslib/package.json.
54
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
55
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-crypto/crc32/node_modules/tslib/package.json.
56
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
57
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/fetch-http-handler/node_modules/tslib/package.json.
58
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
59
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/eventstream-serde-config-resolver/node_modules/tslib/package.json.
60
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
61
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/util-waiter/node_modules/tslib/package.json.
62
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
63
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/middleware-bucket-endpoint/node_modules/tslib/package.json.
64
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
65
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/middleware-sdk-s3/node_modules/tslib/package.json.
66
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
67
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/hash-blob-browser/node_modules/tslib/package.json.
68
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
69
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/md5-js/node_modules/tslib/package.json.
70
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
71
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/middleware-apply-body-checksum/node_modules/tslib/package.json.
72
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
73
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/middleware-stack/node_modules/tslib/package.json.
74
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
75
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-crypto/sha256-js/node_modules/tslib/package.json.
76
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
77
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-crypto/supports-web-crypto/node_modules/tslib/package.json.
78
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
79
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-crypto/ie11-detection/node_modules/tslib/package.json.
80
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
81
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/querystring-parser/node_modules/tslib/package.json.
82
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
83
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/eventstream-serde-browser/node_modules/tslib/package.json.
84
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
85
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/util-arn-parser/node_modules/tslib/package.json.
86
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
87
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/xml-builder/node_modules/tslib/package.json.
88
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
89
+ @aws-amplify/ui-svelte:build: (node:2153) [DEP0148] DeprecationWarning: Use of deprecated folder mapping "./" in the "exports" field module resolution of the package at /home/runner/work/amplify-ui/amplify-ui/node_modules/@aws-sdk/eventstream-serde-universal/node_modules/tslib/package.json.
90
+ @aws-amplify/ui-svelte:build: Update this package.json to use a subpath pattern like "./*".
91
+ @aws-amplify/ui-svelte:build: 8:04:09 PM [vite-plugin-svelte] The following packages did not export their `package.json` file so we could not check the "svelte" field. If you had difficulties importing svelte components from a package, then please contact the author and ask them to export the package.json file.
92
+ @aws-amplify/ui-svelte:build: - @aws-amplify/ui
93
+ @aws-amplify/ui-svelte:build: ✓ 2081 modules transformed.
94
+ @aws-amplify/ui-svelte:build: rendering chunks...
95
+ @aws-amplify/ui-svelte:build: .svelte-kit/output/client/_app/manifest.json 1.27 KiB
96
+ @aws-amplify/ui-svelte:build: .svelte-kit/output/client/_app/start-773fdc1b.js 19.60 KiB / gzip: 6.79 KiB
97
+ @aws-amplify/ui-svelte:build: .svelte-kit/output/client/_app/layout.svelte-c4c530bc.js 0.53 KiB / gzip: 0.35 KiB
98
+ @aws-amplify/ui-svelte:build: .svelte-kit/output/client/_app/error.svelte-45891722.js 1.56 KiB / gzip: 0.75 KiB
99
+ @aws-amplify/ui-svelte:build: .svelte-kit/output/client/_app/assets/start-d5b4de3e.css 0.19 KiB / gzip: 0.16 KiB
100
+ @aws-amplify/ui-svelte:build: .svelte-kit/output/client/_app/assets/pages/index.svelte-b6b4a4b3.css 125.87 KiB / gzip: 14.07 KiB
101
+ @aws-amplify/ui-svelte:build: .svelte-kit/output/client/_app/pages/index.svelte-1763c7f6.js 120.16 KiB / gzip: 28.41 KiB
102
+ @aws-amplify/ui-svelte:build: .svelte-kit/output/client/_app/chunks/vendor-bcc6beb8.js 462.18 KiB / gzip: 120.95 KiB
103
+ @aws-amplify/ui-svelte:build: vite v2.7.10 building SSR bundle for production...
104
+ @aws-amplify/ui-svelte:build: transforming...
105
+ @aws-amplify/ui-svelte:build: 8:04:21 PM [vite-plugin-svelte] The following packages did not export their `package.json` file so we could not check the "svelte" field. If you had difficulties importing svelte components from a package, then please contact the author and ask them to export the package.json file.
106
+ @aws-amplify/ui-svelte:build: - @aws-amplify/ui
107
+ @aws-amplify/ui-svelte:build: ✓ 453 modules transformed.
108
+ @aws-amplify/ui-svelte:build: rendering chunks...
109
+ @aws-amplify/ui-svelte:build: .svelte-kit/output/server/manifest.json 0.99 KiB
110
+ @aws-amplify/ui-svelte:build: .svelte-kit/output/server/app.js 46.82 KiB
111
+ @aws-amplify/ui-svelte:build: .svelte-kit/output/server/entries/pages/layout.svelte.js 0.24 KiB
112
+ @aws-amplify/ui-svelte:build: .svelte-kit/output/server/entries/pages/error.svelte.js 0.72 KiB
113
+ @aws-amplify/ui-svelte:build: .svelte-kit/output/server/entries/pages/index.svelte.js 356.15 KiB
114
+ @aws-amplify/ui-svelte:build: .svelte-kit/output/server/chunks/index-532f92af.js 5.67 KiB
115
+ @aws-amplify/ui-svelte:build:
116
+ @aws-amplify/ui-svelte:build: Run npm run preview to preview your production build locally.
117
+ @aws-amplify/ui-svelte:build:
118
+ @aws-amplify/ui-svelte:build: > Using @sveltejs/adapter-static
119
+ @aws-amplify/ui-svelte:build: [ERROR] 04:24.367 AuthError -
120
+ @aws-amplify/ui-svelte:build: Error: Amplify has not been configured correctly.
121
+ @aws-amplify/ui-svelte:build: The configuration object is missing required auth properties.
122
+ @aws-amplify/ui-svelte:build: This error is typically caused by one of the following scenarios:
123
+ @aws-amplify/ui-svelte:build:
124
+ @aws-amplify/ui-svelte:build: 1. Did you run `amplify push` after adding auth via `amplify add auth`?
125
+ @aws-amplify/ui-svelte:build: See https://aws-amplify.github.io/docs/js/authentication#amplify-project-setup for more information
126
+ @aws-amplify/ui-svelte:build:
127
+ @aws-amplify/ui-svelte:build: 2. This could also be caused by multiple conflicting versions of amplify packages, see (https://docs.amplify.aws/lib/troubleshooting/upgrading/q/platform/js) for help upgrading Amplify packages.
128
+ @aws-amplify/ui-svelte:build:
129
+ @aws-amplify/ui-svelte:build: ✔ done
130
+ @aws-amplify/ui-svelte:build: $ svelte-kit package
131
+ @aws-amplify/ui-svelte:build: src/lib -> dist
132
+ @aws-amplify/ui-svelte:build: Successfully built '@aws-amplify/ui-svelte' package. To publish it to npm:
133
+ @aws-amplify/ui-svelte:build: cd dist
134
+ @aws-amplify/ui-svelte:build: npm publish
135
+ @aws-amplify/ui-svelte:build:
package/CHANGELOG.md ADDED
@@ -0,0 +1,15 @@
1
+ # @aws-amplify/ui-svelte
2
+
3
+ ## 0.0.0-next-c8114c5-20220105200507
4
+ ### Patch Changes
5
+
6
+
7
+
8
+ - Version bump for all public packages
9
+
10
+
11
+
12
+ - [#1073](https://github.com/aws-amplify/amplify-ui/pull/1073) [`c8114c55f`](https://github.com/aws-amplify/amplify-ui/commit/c8114c55f919f54c63cab01c44d9b189752d078b) Thanks [@ErikCH](https://github.com/ErikCH)! - Added SignIn for svelte
13
+
14
+ - Updated dependencies []:
15
+ - @aws-amplify/ui@0.0.0-next-c8114c5-20220105200507
package/README.md ADDED
@@ -0,0 +1,38 @@
1
+ # create-svelte
2
+
3
+ Everything you need to build a Svelte project, powered by [`create-svelte`](https://github.com/sveltejs/kit/tree/master/packages/create-svelte);
4
+
5
+ ## Creating a project
6
+
7
+ If you're seeing this, you've probably already done this step. Congrats!
8
+
9
+ ```bash
10
+ # create a new project in the current directory
11
+ npm init svelte@next
12
+
13
+ # create a new project in my-app
14
+ npm init svelte@next my-app
15
+ ```
16
+
17
+ > Note: the `@next` is temporary
18
+
19
+ ## Developing
20
+
21
+ Once you've created a project and installed dependencies with `npm install` (or `pnpm install` or `yarn`), start a development server:
22
+
23
+ ```bash
24
+ npm run dev
25
+
26
+ # or start the server and open the app in a new browser tab
27
+ npm run dev -- --open
28
+ ```
29
+
30
+ ## Building
31
+
32
+ Before creating a production version of your app, install an [adapter](https://kit.svelte.dev/docs#adapters) for your target environment. Then:
33
+
34
+ ```bash
35
+ npm run build
36
+ ```
37
+
38
+ > You can preview the built app with `npm run preview`, regardless of whether you installed an adapter. This should _not_ be used to serve your app in production.
package/dist/README.md ADDED
@@ -0,0 +1,38 @@
1
+ # create-svelte
2
+
3
+ Everything you need to build a Svelte project, powered by [`create-svelte`](https://github.com/sveltejs/kit/tree/master/packages/create-svelte);
4
+
5
+ ## Creating a project
6
+
7
+ If you're seeing this, you've probably already done this step. Congrats!
8
+
9
+ ```bash
10
+ # create a new project in the current directory
11
+ npm init svelte@next
12
+
13
+ # create a new project in my-app
14
+ npm init svelte@next my-app
15
+ ```
16
+
17
+ > Note: the `@next` is temporary
18
+
19
+ ## Developing
20
+
21
+ Once you've created a project and installed dependencies with `npm install` (or `pnpm install` or `yarn`), start a development server:
22
+
23
+ ```bash
24
+ npm run dev
25
+
26
+ # or start the server and open the app in a new browser tab
27
+ npm run dev -- --open
28
+ ```
29
+
30
+ ## Building
31
+
32
+ Before creating a production version of your app, install an [adapter](https://kit.svelte.dev/docs#adapters) for your target environment. Then:
33
+
34
+ ```bash
35
+ npm run build
36
+ ```
37
+
38
+ > You can preview the built app with `npm run preview`, regardless of whether you installed an adapter. This should _not_ be used to serve your app in production.
@@ -0,0 +1,43 @@
1
+ <script >import { onDestroy } from 'svelte';
2
+ import { setupMachine, route, toSignIn } from './authStore';
3
+ import SignIn from './SignIn.svelte';
4
+ import AmplifyTabs from './primitives/AmplifyTabs.svelte';
5
+ export let initialState = undefined;
6
+ export let loginMechanisms = undefined;
7
+ export let services = undefined;
8
+ export let signUpAttributes = undefined;
9
+ export let socialProviders = undefined;
10
+ const _subscription = setupMachine(initialState, loginMechanisms, services, signUpAttributes, socialProviders);
11
+ onDestroy(() => {
12
+ if (_subscription)
13
+ _subscription.unsubscribe();
14
+ });
15
+ </script>
16
+
17
+ {#if $route !== 'authenticated'}
18
+ <div data-amplify-authenticator>
19
+ <div data-amplify-container>
20
+ <!--Slot header goes here-->
21
+ <div data-amplify-router>
22
+ {#if $route === 'signIn' || $route === 'signUp'}
23
+ <AmplifyTabs />
24
+ {/if}
25
+
26
+ {#if $route === 'signIn'}
27
+ <SignIn />
28
+ {/if}
29
+ {#if $route === 'signUp'}
30
+ <p>Sign Up</p>
31
+ <button on:click={toSignIn}>To Sign In</button>
32
+ {/if}
33
+ {#if $route === 'resetPassword'}
34
+ <p>reset password</p>
35
+ <button on:click={toSignIn}>To Sign In</button>
36
+ {/if}
37
+ </div>
38
+ </div>
39
+ </div>
40
+ {/if}
41
+ {#if $route === 'authenticated'}
42
+ <slot />
43
+ {/if}
@@ -0,0 +1,22 @@
1
+ import { SvelteComponentTyped } from "svelte";
2
+ declare const __propDef: {
3
+ props: {
4
+ initialState?: any;
5
+ loginMechanisms?: any;
6
+ services?: any;
7
+ signUpAttributes?: any;
8
+ socialProviders?: any;
9
+ };
10
+ events: {
11
+ [evt: string]: CustomEvent<any>;
12
+ };
13
+ slots: {
14
+ default: {};
15
+ };
16
+ };
17
+ export declare type AuthenticatorProps = typeof __propDef.props;
18
+ export declare type AuthenticatorEvents = typeof __propDef.events;
19
+ export declare type AuthenticatorSlots = typeof __propDef.slots;
20
+ export default class Authenticator extends SvelteComponentTyped<AuthenticatorProps, AuthenticatorEvents, AuthenticatorSlots> {
21
+ }
22
+ export {};
@@ -0,0 +1,69 @@
1
+ <script >import AmplifyFormField from './primitives/AmplifyFormField.svelte';
2
+ import AmplifyError from './primitives/AmplifyError.svelte';
3
+ import UserNameAlias from './UserNameAlias.svelte';
4
+ import AmplifyButton from './primitives/AmplifyButton.svelte';
5
+ import { translate } from '@aws-amplify/ui';
6
+ import { updateForm, submitForm, isPending, error, toResetPassword, } from './authStore';
7
+ const forgotPasswordText = translate('Forgot your password? ');
8
+ const signInButtonText = translate('Sign in');
9
+ const signingButtonText = translate('Signing in');
10
+ function onInput(event) {
11
+ event.preventDefault();
12
+ const { name, value } = event.target;
13
+ updateForm({ name, value });
14
+ }
15
+ function onSubmit(event) {
16
+ event.preventDefault();
17
+ submitForm();
18
+ }
19
+ </script>
20
+
21
+ <div data-amplify-container>
22
+ <form
23
+ data-amplify-form
24
+ on:submit|preventDefault={onSubmit}
25
+ on:input={onInput}
26
+ >
27
+ <fieldset
28
+ class="amplify-flex"
29
+ style="flex-direction: column"
30
+ data-amplify-fieldset
31
+ disabled={$isPending}
32
+ >
33
+ <UserNameAlias />
34
+ <AmplifyFormField
35
+ data-amplify-password
36
+ name="password"
37
+ type="password"
38
+ autocomplete="current-password"
39
+ />
40
+ <AmplifyButton
41
+ disabled={$isPending}
42
+ variation="primary"
43
+ fullWidth="true"
44
+ type="submit"
45
+ >
46
+ {$isPending ? signingButtonText : signInButtonText}
47
+ </AmplifyButton>
48
+
49
+ {#if $error}
50
+ <AmplifyError>
51
+ {$error}
52
+ </AmplifyError>
53
+ {/if}
54
+ </fieldset>
55
+ </form>
56
+
57
+ <div data-amplify-footer>
58
+ <AmplifyButton
59
+ amplify-button
60
+ fontWeight="normal"
61
+ data-size="small"
62
+ variation="link"
63
+ fullWidth="true"
64
+ on:click={toResetPassword}
65
+ >
66
+ {forgotPasswordText}
67
+ </AmplifyButton>
68
+ </div>
69
+ </div>
@@ -0,0 +1,14 @@
1
+ import { SvelteComponentTyped } from "svelte";
2
+ declare const __propDef: {
3
+ props: {};
4
+ events: {
5
+ [evt: string]: CustomEvent<any>;
6
+ };
7
+ slots: {};
8
+ };
9
+ export declare type SignInProps = typeof __propDef.props;
10
+ export declare type SignInEvents = typeof __propDef.events;
11
+ export declare type SignInSlots = typeof __propDef.slots;
12
+ export default class SignIn extends SvelteComponentTyped<SignInProps, SignInEvents, SignInSlots> {
13
+ }
14
+ export {};
@@ -0,0 +1,29 @@
1
+ <script >import AmplifyFormField from './primitives/AmplifyFormField.svelte';
2
+ import { onMount } from 'svelte';
3
+ import { authState } from './authStore';
4
+ import { getAliasInfoFromContext } from '@aws-amplify/ui';
5
+ export let name = 'username';
6
+ export let disabled = false;
7
+ export let initialValue = '';
8
+ export let required = true;
9
+ let label;
10
+ let type;
11
+ let error;
12
+ let placeholder;
13
+ onMount(() => {
14
+ const { label, type } = getAliasInfoFromContext($authState.context);
15
+ placeholder = label;
16
+ });
17
+ </script>
18
+
19
+ <AmplifyFormField
20
+ data-amplify-usernamealias
21
+ {name}
22
+ {label}
23
+ {type}
24
+ {placeholder}
25
+ {initialValue}
26
+ {disabled}
27
+ {required}
28
+ autocomplete="username"
29
+ />
@@ -0,0 +1,19 @@
1
+ import { SvelteComponentTyped } from "svelte";
2
+ declare const __propDef: {
3
+ props: {
4
+ name?: string;
5
+ disabled?: boolean;
6
+ initialValue?: string;
7
+ required?: boolean;
8
+ };
9
+ events: {
10
+ [evt: string]: CustomEvent<any>;
11
+ };
12
+ slots: {};
13
+ };
14
+ export declare type UserNameAliasProps = typeof __propDef.props;
15
+ export declare type UserNameAliasEvents = typeof __propDef.events;
16
+ export declare type UserNameAliasSlots = typeof __propDef.slots;
17
+ export default class UserNameAlias extends SvelteComponentTyped<UserNameAliasProps, UserNameAliasEvents, UserNameAliasSlots> {
18
+ }
19
+ export {};
@@ -0,0 +1,20 @@
1
+ export declare const error: import("svelte/store").Writable<any>;
2
+ export declare const route: import("svelte/store").Writable<any>;
3
+ export declare const isPending: import("svelte/store").Writable<any>;
4
+ export declare const hasValidationErrors: import("svelte/store").Writable<any>;
5
+ export declare const user: import("svelte/store").Writable<any>;
6
+ export declare const validationErrors: import("svelte/store").Writable<any>;
7
+ export declare const codeDeliveryDetails: import("svelte/store").Writable<any>;
8
+ /** @deprecated For internal use only */
9
+ export declare const authState: import("svelte/store").Writable<any>;
10
+ export declare function setupMachine(initialState: any, loginMechanisms: any, services: any, signUpAttributes: any, socialProviders: any): import("xstate").Subscription;
11
+ export declare function updateForm(...args: any[]): void;
12
+ export declare function updateBlur(...args: any[]): void;
13
+ export declare function resendCode(...args: any[]): void;
14
+ export declare function signOut(...args: any[]): void;
15
+ export declare function submitForm(...args: any[]): void;
16
+ export declare function toFederatedSignIn(...args: any[]): void;
17
+ export declare function toResetPassword(...args: any[]): void;
18
+ export declare function toSignIn(...args: any[]): void;
19
+ export declare function toSignUp(...args: any[]): void;
20
+ export declare function skipVerification(...args: any[]): void;
@@ -0,0 +1,100 @@
1
+ import { createAuthenticatorMachine, getServiceContextFacade, getSendEventAliases, translate, } from '@aws-amplify/ui';
2
+ import { interpret } from 'xstate';
3
+ import { writable, get } from 'svelte/store';
4
+ let _facade = writable(null);
5
+ export const error = writable(null);
6
+ export const route = writable(null);
7
+ export const isPending = writable(null);
8
+ export const hasValidationErrors = writable(null);
9
+ export const user = writable(null);
10
+ export const validationErrors = writable(null);
11
+ export const codeDeliveryDetails = writable(null);
12
+ const _sendEventAliases = writable(null);
13
+ /** @deprecated For internal use only */
14
+ export const authState = writable(null);
15
+ export function setupMachine(initialState, loginMechanisms, services, signUpAttributes, socialProviders) {
16
+ const machine = createAuthenticatorMachine({
17
+ initialState,
18
+ loginMechanisms,
19
+ services,
20
+ signUpAttributes,
21
+ socialProviders,
22
+ });
23
+ const authService = interpret(machine, {
24
+ devTools: process.env.NODE_ENV === 'development',
25
+ }).start();
26
+ const subscription = authService.subscribe((state) => {
27
+ authState.update(() => state);
28
+ _facade.update(() => getServiceContextFacade(state));
29
+ setError();
30
+ setRoute();
31
+ setHasValidationErrors();
32
+ setCodeDeliveryDetails();
33
+ setIsPending();
34
+ setUser();
35
+ setValidationErrors();
36
+ });
37
+ _sendEventAliases.set(getSendEventAliases(authService.send));
38
+ const _authService = authService;
39
+ return subscription;
40
+ }
41
+ /**
42
+ * Context facades
43
+ */
44
+ function setError() {
45
+ error.set(translate(get(_facade).error));
46
+ }
47
+ function setRoute() {
48
+ route.set(get(_facade).route);
49
+ }
50
+ function setHasValidationErrors() {
51
+ hasValidationErrors.set(get(_facade).hasValidationErrors);
52
+ }
53
+ function setIsPending() {
54
+ isPending.set(get(_facade).isPending);
55
+ }
56
+ function setUser() {
57
+ user.set(get(_facade).user);
58
+ }
59
+ function setValidationErrors() {
60
+ validationErrors.set(get(_facade).validationErrors);
61
+ }
62
+ function setCodeDeliveryDetails() {
63
+ codeDeliveryDetails.set(get(_facade).codeDeliveryDetails);
64
+ }
65
+ // /**
66
+ // * Service facades
67
+ // */
68
+ export function updateForm(...args) {
69
+ return get(_sendEventAliases).updateForm(...args);
70
+ }
71
+ export function updateBlur(...args) {
72
+ return get(_sendEventAliases).updateBlur(...args);
73
+ }
74
+ export function resendCode(...args) {
75
+ return get(_sendEventAliases).resendCode(...args);
76
+ }
77
+ export function signOut(...args) {
78
+ return get(_sendEventAliases).signOut(...args);
79
+ }
80
+ export function submitForm(...args) {
81
+ return get(_sendEventAliases).submitForm(...args);
82
+ }
83
+ // /**
84
+ // * Transition facades
85
+ // */
86
+ export function toFederatedSignIn(...args) {
87
+ return get(_sendEventAliases).toFederatedSignIn(...args);
88
+ }
89
+ export function toResetPassword(...args) {
90
+ return get(_sendEventAliases).toResetPassword(...args);
91
+ }
92
+ export function toSignIn(...args) {
93
+ return get(_sendEventAliases).toSignIn(...args);
94
+ }
95
+ export function toSignUp(...args) {
96
+ return get(_sendEventAliases).toSignUp(...args);
97
+ }
98
+ export function skipVerification(...args) {
99
+ return get(_sendEventAliases).skipVerification(...args);
100
+ }
@@ -0,0 +1,23 @@
1
+ <script >import { createEventDispatcher } from 'svelte';
2
+ export let type = 'button';
3
+ export let fullWidth = false;
4
+ export let size = 'medium';
5
+ export let variation = 'default';
6
+ export let fontWeight = 'normal';
7
+ const dispatch = createEventDispatcher();
8
+ </script>
9
+
10
+ <button
11
+ {...$$restProps}
12
+ on:click={() => dispatch('click')}
13
+ class={`amplify-button ${$$props.class ?? ''}`}
14
+ {type}
15
+ style="font-weight: {fontWeight} "
16
+ data-fullwidth={fullWidth}
17
+ data-size={size}
18
+ data-fontWeight={fontWeight}
19
+ data-variation={variation}
20
+ data-amplify-button=""
21
+ >
22
+ <slot />
23
+ </button>
@@ -0,0 +1,25 @@
1
+ import { SvelteComponentTyped } from "svelte";
2
+ declare const __propDef: {
3
+ props: {
4
+ [x: string]: any;
5
+ type?: 'submit' | 'button';
6
+ fullWidth?: boolean | string;
7
+ size?: 'small' | 'medium' | 'large';
8
+ variation?: 'primary' | 'default' | 'link';
9
+ fontWeight?: 'normal' | 'bold' | 'lighter';
10
+ };
11
+ events: {
12
+ click: CustomEvent<any>;
13
+ } & {
14
+ [evt: string]: CustomEvent<any>;
15
+ };
16
+ slots: {
17
+ default: {};
18
+ };
19
+ };
20
+ export declare type AmplifyButtonProps = typeof __propDef.props;
21
+ export declare type AmplifyButtonEvents = typeof __propDef.events;
22
+ export declare type AmplifyButtonSlots = typeof __propDef.slots;
23
+ export default class AmplifyButton extends SvelteComponentTyped<AmplifyButtonProps, AmplifyButtonEvents, AmplifyButtonSlots> {
24
+ }
25
+ export {};