@rotki/ui-library 0.16.0 → 1.0.0-beta.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 (83) hide show
  1. package/README.md +3 -3
  2. package/dist/RuiNavigationDrawer-DgxZEmkN.js +7848 -0
  3. package/dist/__test__/options.d.ts +5 -0
  4. package/dist/{breakpoint-DAvEs_TA.js → breakpoint-OTAceaTK.js} +1 -1
  5. package/dist/components/accordions/accordion/RuiAccordion.vue.d.ts +32 -45
  6. package/dist/components/accordions/accordions/RuiAccordions.vue.d.ts +25 -20
  7. package/dist/components/alerts/RuiAlert.vue.d.ts +37 -61
  8. package/dist/components/buttons/button/RuiButton.vue.d.ts +52 -9
  9. package/dist/components/buttons/button-group/RuiButtonGroup.vue.d.ts +43 -9
  10. package/dist/components/cards/RuiCard.vue.d.ts +33 -52
  11. package/dist/components/cards/RuiCardHeader.vue.d.ts +22 -11
  12. package/dist/components/chips/RuiChip.vue.d.ts +44 -87
  13. package/dist/components/color-picker/RuiColorBoard.vue.d.ts +15 -12
  14. package/dist/components/color-picker/RuiColorDisplay.vue.d.ts +13 -10
  15. package/dist/components/color-picker/RuiColorHue.vue.d.ts +16 -10
  16. package/dist/components/color-picker/RuiColorInput.vue.d.ts +16 -10
  17. package/dist/components/color-picker/RuiColorPicker.vue.d.ts +23 -12
  18. package/dist/components/divider/RuiDivider.vue.d.ts +22 -11
  19. package/dist/components/forms/checkbox/RuiCheckbox.vue.d.ts +42 -85
  20. package/dist/components/forms/radio-button/radio/RuiRadio.vue.d.ts +40 -85
  21. package/dist/components/forms/radio-button/radio-group/RuiRadioGroup.vue.d.ts +43 -86
  22. package/dist/components/forms/revealable-text-field/RuiRevealableTextField.vue.d.ts +61 -146
  23. package/dist/components/forms/select/RuiMenuSelect.vue.d.ts +159 -46
  24. package/dist/components/forms/select/RuiSimpleSelect.vue.d.ts +27 -44
  25. package/dist/components/forms/slider/RuiSlider.vue.d.ts +61 -152
  26. package/dist/components/forms/switch/RuiSwitch.vue.d.ts +40 -77
  27. package/dist/components/forms/text-area/RuiTextArea.vue.d.ts +69 -178
  28. package/dist/components/forms/text-field/RuiTextField.vue.d.ts +62 -147
  29. package/dist/components/helpers/RuiFormTextDetail.vue.d.ts +34 -27
  30. package/dist/components/icons/RuiIcon.vue.d.ts +24 -27
  31. package/dist/components/index.d.ts +4 -2
  32. package/dist/components/index.es.js +25 -23
  33. package/dist/components/loaders/RuiSkeletonBase.vue.d.ts +23 -12
  34. package/dist/components/loaders/RuiSkeletonLoader.vue.d.ts +26 -21
  35. package/dist/components/logos/RuiLogo.vue.d.ts +30 -43
  36. package/dist/components/overlays/badge/RuiBadge.vue.d.ts +46 -95
  37. package/dist/components/overlays/bottom-sheet/RuiBottomSheet.vue.d.ts +24 -31
  38. package/dist/components/overlays/dialog/RuiDialog.vue.d.ts +34 -53
  39. package/dist/components/overlays/menu/RuiMenu.vue.d.ts +67 -142
  40. package/dist/components/overlays/navigation-drawer/RuiNavigationDrawer.vue.d.ts +81 -0
  41. package/dist/components/overlays/notification/RuiNotification.vue.d.ts +45 -0
  42. package/dist/components/overlays/tooltip/RuiTooltip.vue.d.ts +35 -60
  43. package/dist/components/progress/RuiProgress.vue.d.ts +37 -68
  44. package/dist/components/steppers/RuiFooterStepper.vue.d.ts +30 -45
  45. package/dist/components/steppers/RuiStepper.vue.d.ts +36 -69
  46. package/dist/components/steppers/RuiStepperCustomIcon.vue.d.ts +28 -19
  47. package/dist/components/steppers/RuiStepperIcon.vue.d.ts +28 -19
  48. package/dist/components/tables/RuiDataTable.vue.d.ts +253 -21
  49. package/dist/components/tables/RuiExpandButton.vue.d.ts +23 -20
  50. package/dist/components/tables/RuiTableHead.vue.d.ts +88 -21
  51. package/dist/components/tables/RuiTablePagination.vue.d.ts +27 -36
  52. package/dist/components/tabs/tab/RuiTab.vue.d.ts +55 -106
  53. package/dist/components/tabs/tab-item/RuiTabItem.vue.d.ts +30 -36
  54. package/dist/components/tabs/tab-items/RuiTabItems.vue.d.ts +22 -11
  55. package/dist/components/tabs/tabs/RuiTabs.vue.d.ts +36 -55
  56. package/dist/composables/dropdown-menu.d.ts +18 -6
  57. package/dist/composables/index.es.js +2 -2
  58. package/dist/composables/popper.d.ts +2 -0
  59. package/dist/composables/theme.d.ts +1 -1
  60. package/dist/icons/icons_1.d.ts +44 -44
  61. package/dist/icons/icons_1.es.js +987 -987
  62. package/dist/icons/icons_2.d.ts +60 -60
  63. package/dist/icons/icons_2.es.js +1121 -1121
  64. package/dist/icons/icons_3.d.ts +76 -76
  65. package/dist/icons/icons_3.es.js +1149 -1149
  66. package/dist/icons/icons_4.d.ts +96 -96
  67. package/dist/icons/icons_4.es.js +1193 -1193
  68. package/dist/icons/icons_5.d.ts +132 -132
  69. package/dist/icons/icons_5.es.js +1267 -1267
  70. package/dist/icons/icons_6.d.ts +156 -0
  71. package/dist/icons/icons_6.es.js +1099 -475
  72. package/dist/icons/index.d.ts +3 -1
  73. package/dist/icons/index.es.js +2903 -2741
  74. package/dist/index-NNlkUY_M.js +161 -0
  75. package/dist/index.es.js +2934 -2773
  76. package/dist/style.css +1 -1
  77. package/dist/utils/helpers.d.ts +9 -0
  78. package/dist/utils/is-equal.d.ts +1 -0
  79. package/package.json +31 -32
  80. package/dist/RuiColorPicker.vue_vue_type_script_setup_true_lang-ByCIjyQ_.js +0 -8945
  81. package/dist/components/forms/auto-complete/RuiAutoComplete.vue.d.ts +0 -71
  82. package/dist/components/forms/auto-complete/RuiAutoCompleteSelection.vue.d.ts +0 -30
  83. package/dist/index-RsNqSz2V.js +0 -177
@@ -0,0 +1,161 @@
1
+ import { RiArrowDownLine as x, RiArrowDropDownFill as T, RiArrowLeftDoubleLine as $, RiArrowLeftLine as D, RiArrowLeftSLine as S, RiArrowRightDoubleLine as v, RiArrowRightLine as I, RiArrowRightSLine as U, RiExpandUpDownLine as M } from "./icons/icons_1.es.js";
2
+ import { RiDatabase2Line as B } from "./icons/icons_2.es.js";
3
+ import { RiAlertFill as _, RiAlertLine as j, RiCheckLine as O, RiCheckboxBlankCircleFill as P, RiCheckboxBlankCircleLine as W, RiCheckboxBlankLine as q, RiCheckboxCircleFill as z, RiCheckboxCircleLine as G, RiCheckboxFill as H, RiCheckboxIndeterminateFill as N, RiCloseCircleLine as V, RiCloseFill as J, RiCloseLine as K, RiErrorWarningFill as Q, RiErrorWarningLine as X, RiEyeLine as Y, RiEyeOffLine as Z, RiInformationFill as ee, RiInformationLine as ie } from "./icons/icons_5.es.js";
4
+ import { RiRadioButtonLine as re, RiMoreFill as te } from "./icons/icons_6.es.js";
5
+ import { createGlobalState as oe, createSharedComposable as ne, useColorMode as ae } from "@vueuse/core";
6
+ import { ref as w, computed as p, watch as se } from "vue";
7
+ import { set as g, get as s } from "@vueuse/shared";
8
+ import { c as le } from "./colors-D563Ic3q.js";
9
+ const ye = oe(() => {
10
+ const e = [
11
+ _,
12
+ j,
13
+ x,
14
+ T,
15
+ $,
16
+ D,
17
+ S,
18
+ v,
19
+ I,
20
+ U,
21
+ O,
22
+ P,
23
+ W,
24
+ q,
25
+ z,
26
+ G,
27
+ H,
28
+ N,
29
+ V,
30
+ J,
31
+ K,
32
+ B,
33
+ Q,
34
+ X,
35
+ Y,
36
+ Z,
37
+ ee,
38
+ ie,
39
+ re,
40
+ te,
41
+ M
42
+ ], i = w({});
43
+ return { registeredIcons: i, registerIcons: (t) => {
44
+ g(i, {
45
+ ...s(i),
46
+ ...Object.fromEntries(
47
+ [...e, ...t].map(({ name: r, path: o }) => [r, o])
48
+ )
49
+ });
50
+ } };
51
+ }), a = {
52
+ auto: "auto",
53
+ dark: "dark",
54
+ light: "light"
55
+ };
56
+ function k(e) {
57
+ return Object.fromEntries(
58
+ le.map((i) => [
59
+ i,
60
+ {
61
+ darker: `var(--rui-${e}-${i}-darker)`,
62
+ DEFAULT: `var(--rui-${e}-${i}-main)`,
63
+ lighter: `var(--rui-${e}-${i}-lighter)`
64
+ }
65
+ ])
66
+ );
67
+ }
68
+ const b = {
69
+ dark: k("dark"),
70
+ light: k("light")
71
+ }, C = w({ ...b }), Ee = ne(() => {
72
+ const { state: e, store: i } = ae(), n = p(() => s(i) === a.auto), t = p(() => s(e) === a.light), r = p(() => s(e) === a.dark), o = p(() => s(t) ? s(C).light : s(C).dark), l = (c) => {
73
+ g(i, c || a.auto);
74
+ }, u = () => {
75
+ s(n) ? l(a.light) : s(t) ? l(a.dark) : s(r) && l(a.auto);
76
+ }, h = (c) => {
77
+ g(C, c);
78
+ };
79
+ return {
80
+ config: C,
81
+ init: (c) => {
82
+ l(c.mode ?? a.auto), h(c.config ?? { ...b }), typeof window < "u" && se([t, o], ([y, E]) => {
83
+ const f = /* @__PURE__ */ new Map();
84
+ Object.entries(E).forEach(([d, R]) => {
85
+ f.set(`--rui-${d}-darker`, R.darker), f.set(`--rui-${d}-lighter`, R.lighter), f.set(`--rui-${d}-main`, R.DEFAULT);
86
+ });
87
+ const L = y ? a.light : a.dark;
88
+ f.set("--rui-text-disabled", `var(--rui-${L}-text-disabled)`), f.set("--rui-text-primary", `var(--rui-${L}-text-primary)`), f.set("--rui-text-secondary", `var(--rui-${L}-text-secondary)`);
89
+ const F = document.documentElement.style;
90
+ f.forEach((d, R) => {
91
+ F.setProperty(R, d);
92
+ });
93
+ }, { immediate: !0 });
94
+ },
95
+ isAutoControlled: n,
96
+ isDark: r,
97
+ isLight: t,
98
+ setThemeConfig: h,
99
+ state: e,
100
+ store: i,
101
+ switchThemeScheme: l,
102
+ theme: o,
103
+ toggleThemeMode: u
104
+ };
105
+ }), ce = /\d/, ue = ["-", "_", "/", "."];
106
+ function fe(e = "") {
107
+ if (!ce.test(e))
108
+ return e !== e.toLowerCase();
109
+ }
110
+ function A(e, i) {
111
+ const n = i ?? ue, t = [];
112
+ if (!e || typeof e != "string")
113
+ return t;
114
+ let r = "", o, l;
115
+ for (const u of e) {
116
+ const h = n.includes(u);
117
+ if (h === !0) {
118
+ t.push(r), r = "", o = void 0;
119
+ continue;
120
+ }
121
+ const m = fe(u);
122
+ if (l === !1) {
123
+ if (o === !1 && m === !0) {
124
+ t.push(r), r = u, o = m;
125
+ continue;
126
+ }
127
+ if (o === !0 && m === !1 && r.length > 1) {
128
+ const c = r.at(-1);
129
+ t.push(r.slice(0, Math.max(0, r.length - 1))), r = c + u, o = m;
130
+ continue;
131
+ }
132
+ }
133
+ r += u, o = m, l = h;
134
+ }
135
+ return t.push(r), t;
136
+ }
137
+ function me(e) {
138
+ return e ? e[0].toUpperCase() + e.slice(1) : "";
139
+ }
140
+ function he(e) {
141
+ return e ? e[0].toLowerCase() + e.slice(1) : "";
142
+ }
143
+ function de(e, i) {
144
+ return e ? (Array.isArray(e) ? e : A(e)).map((n) => me(i != null && i.normalize ? n.toLowerCase() : n)).join("") : "";
145
+ }
146
+ function Fe(e, i) {
147
+ return he(de(e || "", i));
148
+ }
149
+ function Re(e, i) {
150
+ return e ? (Array.isArray(e) ? e : A(e)).map((n) => n.toLowerCase()).join(i ?? "-") : "";
151
+ }
152
+ function xe(e) {
153
+ return Re(e || "", "_");
154
+ }
155
+ export {
156
+ a as T,
157
+ Ee as a,
158
+ Fe as c,
159
+ xe as s,
160
+ ye as u
161
+ };