@simsustech/quasar-components 0.1.1 → 0.1.2

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 (46) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/dist/QSubmitButton.vue_vue_type_script_setup_true_lang.fe90878f.js +93 -0
  3. package/dist/authentication.js +1633 -0
  4. package/dist/flags.js +217 -0
  5. package/dist/general.js +81 -0
  6. package/dist/icons.js +23 -0
  7. package/dist/nl.6b0aedb7.js +89 -0
  8. package/dist/nl.7787ff31.js +9 -0
  9. package/dist/nl.b1ad9de9.js +134 -0
  10. package/dist/style.css +4 -0
  11. package/dist/types/ui/authentication/ConsentList.vue.d.ts +85 -0
  12. package/dist/types/ui/authentication/EmailChangeForm.vue.d.ts +147 -0
  13. package/dist/types/ui/authentication/EmailChangeStepper.vue.d.ts +168 -0
  14. package/dist/types/ui/authentication/LoginButton.vue.d.ts +69 -0
  15. package/dist/types/ui/authentication/LoginForm.vue.d.ts +157 -0
  16. package/dist/types/ui/authentication/OtpInput.vue.d.ts +69 -0
  17. package/dist/types/ui/authentication/PasswordChangeForm.vue.d.ts +187 -0
  18. package/dist/types/ui/authentication/PasswordChangeStepper.vue.d.ts +168 -0
  19. package/dist/types/ui/authentication/RegisterForm.vue.d.ts +230 -0
  20. package/dist/types/ui/authentication/RequestOtpForm.vue.d.ts +132 -0
  21. package/dist/types/ui/authentication/UserMenuButton.vue.d.ts +82 -0
  22. package/dist/types/ui/authentication/VerificationSlider.vue.d.ts +77 -0
  23. package/dist/types/ui/authentication/index.d.ts +12 -0
  24. package/dist/types/ui/authentication/lang/en-US.d.ts +3 -0
  25. package/dist/types/ui/authentication/lang/index.d.ts +176 -0
  26. package/dist/types/ui/authentication/lang/nl.d.ts +3 -0
  27. package/dist/types/ui/flags/index.d.ts +3 -0
  28. package/dist/types/ui/flags/lang/en-US.d.ts +3 -0
  29. package/dist/types/ui/flags/lang/index.d.ts +266 -0
  30. package/dist/types/ui/flags/lang/nl.d.ts +3 -0
  31. package/dist/types/ui/general/QStyledCard.vue.d.ts +74 -0
  32. package/dist/types/ui/general/QStyledLayout.vue.d.ts +69 -0
  33. package/dist/types/ui/general/QSubmitButton.vue.d.ts +138 -0
  34. package/dist/types/ui/general/index.d.ts +2 -0
  35. package/dist/types/ui/general/lang/en-US.d.ts +3 -0
  36. package/dist/types/ui/general/lang/index.d.ts +16 -0
  37. package/dist/types/ui/general/lang/nl.d.ts +3 -0
  38. package/dist/types/ui/icons/icons.d.ts +6 -0
  39. package/dist/types/ui/icons/index.d.ts +2 -0
  40. package/dist/types/ui/index.d.ts +2 -0
  41. package/dist/types/vite-plugin.d.ts +2 -0
  42. package/dist/vite-plugin.d.ts +2 -0
  43. package/dist/vite-plugin.js +66 -0
  44. package/package.json +1 -1
  45. package/src/ui/authentication/EmailChangeForm.vue +2 -2
  46. package/src/ui/authentication/RequestOtpForm.vue +1 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @simsustech/quasar-components
2
2
 
3
+ ## 0.1.2
4
+
5
+ ### Patch Changes
6
+
7
+ - 5bdc2d0: Trim email in EmailChange and RequestOtp forms
8
+
3
9
  ## 0.1.1
4
10
 
5
11
  ### Patch Changes
@@ -0,0 +1,93 @@
1
+ import { useQuasar, QBtn } from "quasar";
2
+ import { ref, defineComponent, useAttrs, watch, openBlock, createBlock, mergeProps, unref } from "vue";
3
+ const lang$1 = {
4
+ isoName: "en-US",
5
+ submit: "Submit",
6
+ next: "Next",
7
+ back: "Back"
8
+ };
9
+ const enUS = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
10
+ __proto__: null,
11
+ default: lang$1
12
+ }, Symbol.toStringTag, { value: "Module" }));
13
+ const lang = ref(lang$1);
14
+ const locales = /* @__PURE__ */ Object.assign({ "./en-US.ts": () => Promise.resolve().then(() => enUS), "./nl.ts": () => import("./nl.7787ff31.js") });
15
+ const useLang = () => {
16
+ return lang;
17
+ };
18
+ let loadingLanguage = false;
19
+ const loadLang = async (isoName) => {
20
+ if (!loadingLanguage) {
21
+ loadingLanguage = true;
22
+ try {
23
+ const data = (await locales[`./${isoName}.ts`]()).default;
24
+ if (data) {
25
+ lang.value = data;
26
+ }
27
+ } catch (e) {
28
+ if ({ "BASE_URL": "/", "MODE": "production", "DEV": false, "PROD": true }.DEBUG)
29
+ console.error(e);
30
+ throw new Error(
31
+ `[quasar-components] Failed to load ${isoName} language file.`
32
+ );
33
+ }
34
+ loadingLanguage = false;
35
+ }
36
+ };
37
+ const __default__ = {
38
+ name: "QSubmitButton",
39
+ inheritAttrs: false
40
+ };
41
+ const _sfc_main = /* @__PURE__ */ defineComponent({
42
+ ...__default__,
43
+ props: {
44
+ loading: {
45
+ type: Boolean,
46
+ default: void 0
47
+ },
48
+ useForm: {
49
+ type: Boolean
50
+ },
51
+ isNextButton: {
52
+ type: Boolean
53
+ }
54
+ },
55
+ emits: ["submit"],
56
+ setup(__props, { emit }) {
57
+ const props = __props;
58
+ const attrs = useAttrs();
59
+ const $q = useQuasar();
60
+ const lang2 = useLang();
61
+ if (lang2.value.isoName !== $q.lang.isoName)
62
+ loadLang($q.lang.isoName);
63
+ watch($q.lang, (val) => {
64
+ loadLang($q.lang.isoName);
65
+ });
66
+ let loadingInternal = ref(false);
67
+ const submit = () => {
68
+ if (props.loading === void 0)
69
+ loadingInternal.value = true;
70
+ new Promise((resolve, reject) => {
71
+ emit("submit", { done: () => resolve(true) });
72
+ }).finally(() => {
73
+ if (props.loading === void 0)
74
+ loadingInternal.value = false;
75
+ });
76
+ };
77
+ return (_ctx, _cache) => {
78
+ const _component_q_btn = QBtn;
79
+ return openBlock(), createBlock(_component_q_btn, mergeProps(unref(attrs), {
80
+ label: __props.isNextButton ? unref(lang2).next : unref(lang2).submit,
81
+ color: "primary",
82
+ loading: __props.loading || unref(loadingInternal),
83
+ type: __props.useForm ? "submit" : void 0,
84
+ onClick: submit
85
+ }), null, 16, ["label", "loading", "type"]);
86
+ };
87
+ }
88
+ });
89
+ export {
90
+ _sfc_main as _,
91
+ loadLang as l,
92
+ useLang as u
93
+ };