@oneb/ui-vue 0.3.13 → 0.3.15

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 (75) hide show
  1. package/dist/CheckIcon-09b84cf5.cjs +1 -0
  2. package/dist/CheckIcon-f1c94824.js +20 -0
  3. package/dist/ChevronDownIcon-6805ce6c.js +20 -0
  4. package/dist/ChevronDownIcon-6889ac87.cjs +1 -0
  5. package/dist/{ChevronRightIcon-8df1af46.js → ChevronRightIcon-4549a26b.js} +4 -21
  6. package/dist/ChevronRightIcon-7a2f0c20.cjs +1 -0
  7. package/dist/NoSymbolIcon-5d326416.cjs +1 -0
  8. package/dist/NoSymbolIcon-e58a9aee.js +71 -0
  9. package/dist/OneHelpMenu-66a2d4c2.cjs +1 -0
  10. package/dist/OneHelpMenu-d7a39a69.js +856 -0
  11. package/dist/OneMarkdown.vue_vue_type_style_index_0_lang-0ea8fbf8.cjs +1 -0
  12. package/dist/OneMarkdown.vue_vue_type_style_index_0_lang-4ed993c7.js +1 -0
  13. package/dist/{SpinnerIcon-516264ba.js → SpinnerIcon-74648c98.js} +6 -5
  14. package/dist/SpinnerIcon-ccb6f3fc.cjs +1 -0
  15. package/dist/SpinnerIcon.vue_vue_type_style_index_0_lang-0ea8fbf8.cjs +1 -0
  16. package/dist/SpinnerIcon.vue_vue_type_style_index_0_lang-4ed993c7.js +1 -0
  17. package/dist/button/index.cjs +1 -1
  18. package/dist/button/index.js +17 -16
  19. package/dist/buttonGroup/index.cjs +1 -0
  20. package/dist/buttonGroup/index.js +31 -0
  21. package/dist/checkbox/index.cjs +1 -0
  22. package/dist/checkbox/index.js +124 -0
  23. package/dist/collapse/index.cjs +1 -0
  24. package/dist/collapse/index.js +58 -0
  25. package/dist/common/index.cjs +1 -16
  26. package/dist/common/index.js +14 -3120
  27. package/dist/dataTable/index.cjs +1 -1
  28. package/dist/dataTable/index.js +846 -9
  29. package/dist/dropdown/index.cjs +1 -1
  30. package/dist/dropdown/index.js +792 -17
  31. package/dist/entityPicker/index.cjs +1 -0
  32. package/dist/entityPicker/index.js +584 -0
  33. package/dist/errorsPage/index.cjs +1 -0
  34. package/dist/errorsPage/index.js +63 -0
  35. package/dist/floating-ui.dom-2121a4fd.cjs +1 -0
  36. package/dist/floating-ui.dom-4509432e.js +941 -0
  37. package/dist/i18n/index.cjs +1 -0
  38. package/dist/{useI18n-2103b39e.js → i18n/index.js} +4 -4
  39. package/dist/index.cjs +1 -1
  40. package/dist/index.js +114 -10295
  41. package/dist/indicators/index.cjs +1 -0
  42. package/dist/indicators/index.js +84 -0
  43. package/dist/infobox/index.cjs +1 -0
  44. package/dist/infobox/index.js +111 -0
  45. package/dist/label/index.cjs +1 -0
  46. package/dist/label/index.js +47 -0
  47. package/dist/layout/index.cjs +1 -1
  48. package/dist/layout/index.js +115 -109
  49. package/dist/modal/index.cjs +1 -0
  50. package/dist/modal/index.js +41 -0
  51. package/dist/periodPicker/index.cjs +1 -0
  52. package/dist/periodPicker/index.js +1323 -0
  53. package/dist/radio/index.cjs +1 -0
  54. package/dist/radio/index.js +73 -0
  55. package/dist/skeleton/index.cjs +1 -0
  56. package/dist/skeleton/index.js +46 -0
  57. package/dist/style.css +1 -1
  58. package/dist/switch/index.cjs +1 -0
  59. package/dist/switch/index.js +142 -0
  60. package/dist/toast/index.cjs +1 -0
  61. package/dist/toast/index.js +140 -0
  62. package/dist/tooltip/index.cjs +1 -0
  63. package/dist/tooltip/index.js +20 -0
  64. package/dist/useModal-85f57682.js +177 -0
  65. package/dist/useModal-98810f6a.cjs +1 -0
  66. package/package.json +4 -4
  67. package/dist/ChevronRightIcon-6aa413c4.cjs +0 -1
  68. package/dist/OneHelpMenu-8e315cb3.js +0 -1791
  69. package/dist/OneHelpMenu-95ae3d5a.cjs +0 -1
  70. package/dist/SpinnerIcon-01be39fe.cjs +0 -1
  71. package/dist/index-19e93dfb.js +0 -954
  72. package/dist/index-85e729ab.cjs +0 -1
  73. package/dist/index-8b41a099.cjs +0 -1
  74. package/dist/index-98daa7ed.js +0 -862
  75. package/dist/useI18n-bcf9c640.cjs +0 -1
@@ -1,13 +1,14 @@
1
1
  import { openBlock as n, createElementBlock as o, createElementVNode as t } from "vue";
2
- import { _ as s } from "./_plugin-vue_export-helper-dad06003.js";
3
- const i = {}, r = {
2
+ import "./SpinnerIcon.vue_vue_type_style_index_0_lang-4ed993c7.js";
3
+ import { _ as r } from "./_plugin-vue_export-helper-dad06003.js";
4
+ const i = {}, s = {
4
5
  class: "spinner",
5
6
  xmlns: "http://www.w3.org/2000/svg",
6
7
  viewBox: "0 0 24 24",
7
8
  style: { animation: "one-sp-ico-rot 2.7s linear infinite" }
8
9
  };
9
10
  function c(l, e) {
10
- return n(), o("svg", r, [...e[0] || (e[0] = [
11
+ return n(), o("svg", s, [...e[0] || (e[0] = [
11
12
  t("circle", {
12
13
  style: { "stroke-linecap": "round", animation: "one-sp-ico-dash 1.7s ease-in-out infinite" },
13
14
  class: "opacity-75",
@@ -20,7 +21,7 @@ function c(l, e) {
20
21
  }, null, -1)
21
22
  ])]);
22
23
  }
23
- const p = /* @__PURE__ */ s(i, [["render", c]]);
24
+ const f = /* @__PURE__ */ r(i, [["render", c]]);
24
25
  export {
25
- p as S
26
+ f as S
26
27
  };
@@ -0,0 +1 @@
1
+ "use strict";const e=require("vue");require("./SpinnerIcon.vue_vue_type_style_index_0_lang-0ea8fbf8.cjs");const o=require("./_plugin-vue_export-helper-f246444f.cjs"),r={},t={class:"spinner",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",style:{animation:"one-sp-ico-rot 2.7s linear infinite"}};function i(c,n){return e.openBlock(),e.createElementBlock("svg",t,[...n[0]||(n[0]=[e.createElementVNode("circle",{style:{"stroke-linecap":"round",animation:"one-sp-ico-dash 1.7s ease-in-out infinite"},class:"opacity-75",cx:"12",cy:"12",r:"8",fill:"none",stroke:"currentColor","stroke-width":"2"},null,-1)])])}const s=o._export_sfc(r,[["render",i]]);exports.SpinnerIcon=s;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),c=require("../SpinnerIcon-01be39fe.cjs");require("../_plugin-vue_export-helper-f246444f.cjs");const m={variant:{type:String,default:"primary"},size:{type:String,default:"md"},label:{type:String},labelClass:{type:String,default:""},icon:{type:[Function,Object]},isLoading:{type:Boolean},isSubmit:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},active:{type:Boolean,default:!1},iconClass:{type:[String,Array]},iconAfter:{type:[Function,Object,String]}},y=["relative inline-flex","border","items-center justify-center","font-semibold whitespace-nowrap","disabled:opacity-30 disabled:cursor-default","focus:outline-none focus:ring-2","transition-colors duration-200"],v={xs:["h-6 px-2.5 text-xs"],sm:["px-2 py-1 text-sm"],md:["h-[40px] px-4 text-sm"],lg:["h-[52px] px-5 text-base"]},h={primary:["rounded-10 border-transparent bg-primary-base disabled:bg-[#979CA9] text-sm text-white hover:bg-primary-hover active:bg-primary-active focus:ring-primary-glow"],secondary:["rounded-10 border-primary-stroke bg-white text-secondary-base text-sm hover:bg-light-body-active active:bg-light-body focus:ring-primary-glow"],info:["rounded-10 border-transparent bg-info-base disabled:bg-[#979CA9] text-white text-sm hover:bg-info-hover active:bg-info-active focus:ring-info-glow"],success:["rounded-10 border-transparent bg-success-base disabled:bg-[#979CA9] text-white text-sm hover:bg-success-hover active:bg-success-active focus:ring-success-glow"],warning:["rounded-10 border-transparent bg-warning-base disabled:bg-[#979CA9] text-white text-sm hover:bg-warning-hover active:bg-warning-active focus:ring-warning-glow"],danger:["rounded-10 border-transparent bg-danger-base disabled:bg-[#979CA9] text-white text-sm hover:bg-danger-hover active:bg-danger-active focus:ring-danger-glow"],tertiary:["rounded-10 border-transparent bg-secondary-body text-primary-base text-sm hover:border-primary-base active:bg-primary-body-active focus:ring-primary-glow"],touch:["rounded-full border-transparent text-secondary-base hover:bg-light-body-active active:bg-light-body p-2 text-sm focus:ring-primary-glow"],link:["rounded-md border-transparent items-center text-info-base hover:text-info-hover text-sm"],none:["rounded-md border-transparent text-secondary-base"],mini:["rounded-full border-transparent bg-[#FAFAFA] h-8 px-2 gap-2 text-xs hover:text-success-base focus:ring-primary-glow"],edit:["rounded-md border-transparent bg-tertiary-base text-primary-base text-2xs h-6 px-1.5 hover:border-primary-base active:bg-primary-body-active focus:ring-primary-glow"],send:["rounded-full border-transparent bg-primary-base text-white hover:bg-primary-hover active:bg-primary-active p-[9px] focus:ring-primary-glow"]},f=(a="primary",l="md")=>{const r=[];return r.push(...y),r.push(...h[a]??[]),a!=="touch"&&a!=="mini"&&a!=="edit"&&a!=="send"&&r.push(...v[l]??[]),l==="xs"?r.map(t=>t.replace("rounded-10","rounded-md").replace("font-semibold","font-medium")):r},x=["disabled","title","type"],C=e.defineComponent({__name:"OneButton",props:m,emits:["click"],setup(a,{emit:l}){const r=l,t=a,d=()=>{r("click")},n=e.computed(()=>t.icon),i=e.computed(()=>t.iconAfter),u=e.computed(()=>{const s=f(t.variant,t.size);return t.variant==="edit"?s.push("gap-1.5"):s.push("gap-[10px]"),t.variant==="touch"&&t.active&&s.push("bg-primary-body-active"),s}),p=e.computed(()=>t.disabled||t.isLoading),b=e.computed(()=>t.label&&t.label.length>0&&t.variant!=="touch"&&t.variant!=="send"),g=e.computed(()=>{const s=["inline-block text-ellipsis overflow-hidden"];return t.labelClass!=null&&s.push(t.labelClass),s}),o=e.computed(()=>{const s=[];return t.variant==="edit"?s.push("w-3.5 h-3.5"):t.variant==="send"?s.push("w-5 h-5"):t.size==="xs"?s.push("w-3.5 h-3.5"):t.size==="sm"?s.push("w-3 h-3"):t.size==="lg"?s.push("w-5 h-5"):s.push("w-4 h-4"),typeof t.iconClass=="string"?s.push(t.iconClass):t.iconClass instanceof Array&&s.push(...t.iconClass),s});return(s,w)=>(e.openBlock(),e.createElementBlock("button",{class:e.normalizeClass(u.value),disabled:p.value,title:s.label,type:s.isSubmit?"submit":"button",onClick:e.withModifiers(d,["stop"])},[n.value!=null&&s.isLoading?(e.openBlock(),e.createBlock(c.SpinnerIcon,{key:0,class:e.normalizeClass(o.value)},null,8,["class"])):typeof n.value=="string"?(e.openBlock(),e.createElementBlock("span",{key:1,class:e.normalizeClass(o.value)},e.toDisplayString(n.value),3)):n.value!=null?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(n.value),{key:2,class:e.normalizeClass(o.value)},null,8,["class"])):e.createCommentVNode("",!0),b.value?(e.openBlock(),e.createElementBlock("span",{key:3,class:e.normalizeClass(g.value)},[e.renderSlot(s.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(s.label),1)])],2)):e.createCommentVNode("",!0),i.value!=null&&s.isLoading?(e.openBlock(),e.createBlock(c.SpinnerIcon,{key:4,class:e.normalizeClass(o.value)},null,8,["class"])):typeof i.value=="string"?(e.openBlock(),e.createElementBlock("span",{key:5,class:e.normalizeClass(o.value)},e.toDisplayString(i.value),3)):i.value!=null?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i.value),{key:6,class:e.normalizeClass(o.value)},null,8,["class"])):e.createCommentVNode("",!0)],10,x))}});exports.OneButton=C;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),c=require("../SpinnerIcon-ccb6f3fc.cjs");require("../SpinnerIcon.vue_vue_type_style_index_0_lang-0ea8fbf8.cjs");require("../_plugin-vue_export-helper-f246444f.cjs");const m={variant:{type:String,default:"primary"},size:{type:String,default:"md"},label:{type:String},labelClass:{type:String,default:""},icon:{type:[Function,Object]},isLoading:{type:Boolean},isSubmit:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},active:{type:Boolean,default:!1},iconClass:{type:[String,Array]},iconAfter:{type:[Function,Object,String]}},y=["relative inline-flex","border","items-center justify-center","font-semibold whitespace-nowrap","disabled:opacity-30 disabled:cursor-default","focus:outline-none focus:ring-2","transition-colors duration-200"],v={xs:["h-6 px-2.5 text-xs"],sm:["px-2 py-1 text-sm"],md:["h-[40px] px-4 text-sm"],lg:["h-[52px] px-5 text-base"]},h={primary:["rounded-10 border-transparent bg-primary-base disabled:bg-[#979CA9] text-sm text-white hover:bg-primary-hover active:bg-primary-active focus:ring-primary-glow"],secondary:["rounded-10 border-primary-stroke bg-white text-secondary-base text-sm hover:bg-light-body-active active:bg-light-body focus:ring-primary-glow"],info:["rounded-10 border-transparent bg-info-base disabled:bg-[#979CA9] text-white text-sm hover:bg-info-hover active:bg-info-active focus:ring-info-glow"],success:["rounded-10 border-transparent bg-success-base disabled:bg-[#979CA9] text-white text-sm hover:bg-success-hover active:bg-success-active focus:ring-success-glow"],warning:["rounded-10 border-transparent bg-warning-base disabled:bg-[#979CA9] text-white text-sm hover:bg-warning-hover active:bg-warning-active focus:ring-warning-glow"],danger:["rounded-10 border-transparent bg-danger-base disabled:bg-[#979CA9] text-white text-sm hover:bg-danger-hover active:bg-danger-active focus:ring-danger-glow"],tertiary:["rounded-10 border-transparent bg-secondary-body text-primary-base text-sm hover:border-primary-base active:bg-primary-body-active focus:ring-primary-glow"],touch:["rounded-full border-transparent text-secondary-base hover:bg-light-body-active active:bg-light-body p-2 text-sm focus:ring-primary-glow"],link:["rounded-md border-transparent items-center text-info-base hover:text-info-hover text-sm"],none:["rounded-md border-transparent text-secondary-base"],mini:["rounded-full border-transparent bg-[#FAFAFA] h-8 px-2 gap-2 text-xs hover:text-success-base focus:ring-primary-glow"],edit:["rounded-md border-transparent bg-tertiary-base text-primary-base text-2xs h-6 px-1.5 hover:border-primary-base active:bg-primary-body-active focus:ring-primary-glow"],send:["rounded-full border-transparent bg-primary-base text-white hover:bg-primary-hover active:bg-primary-active p-[9px] focus:ring-primary-glow"]},f=(r="primary",l="md")=>{const a=[];return a.push(...y),a.push(...h[r]??[]),r!=="touch"&&r!=="mini"&&r!=="edit"&&r!=="send"&&a.push(...v[l]??[]),l==="xs"?a.map(t=>t.replace("rounded-10","rounded-md").replace("font-semibold","font-medium")):a},x=["disabled","title","type"],C=e.defineComponent({__name:"OneButton",props:m,emits:["click"],setup(r,{emit:l}){const a=l,t=r,u=()=>{a("click")},n=e.computed(()=>t.icon),i=e.computed(()=>t.iconAfter),d=e.computed(()=>{const s=f(t.variant,t.size);return t.variant==="edit"?s.push("gap-1.5"):s.push("gap-[10px]"),t.variant==="touch"&&t.active&&s.push("bg-primary-body-active"),s}),p=e.computed(()=>t.disabled||t.isLoading),b=e.computed(()=>t.label&&t.label.length>0&&t.variant!=="touch"&&t.variant!=="send"),g=e.computed(()=>{const s=["inline-block text-ellipsis overflow-hidden"];return t.labelClass!=null&&s.push(t.labelClass),s}),o=e.computed(()=>{const s=[];return t.variant==="edit"?s.push("w-3.5 h-3.5"):t.variant==="send"?s.push("w-5 h-5"):t.size==="xs"?s.push("w-3.5 h-3.5"):t.size==="sm"?s.push("w-3 h-3"):t.size==="lg"?s.push("w-5 h-5"):s.push("w-4 h-4"),typeof t.iconClass=="string"?s.push(t.iconClass):t.iconClass instanceof Array&&s.push(...t.iconClass),s});return(s,w)=>(e.openBlock(),e.createElementBlock("button",{class:e.normalizeClass(d.value),disabled:p.value,title:s.label,type:s.isSubmit?"submit":"button",onClick:e.withModifiers(u,["stop"])},[n.value!=null&&s.isLoading?(e.openBlock(),e.createBlock(c.SpinnerIcon,{key:0,class:e.normalizeClass(o.value)},null,8,["class"])):typeof n.value=="string"?(e.openBlock(),e.createElementBlock("span",{key:1,class:e.normalizeClass(o.value)},e.toDisplayString(n.value),3)):n.value!=null?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(n.value),{key:2,class:e.normalizeClass(o.value)},null,8,["class"])):e.createCommentVNode("",!0),b.value?(e.openBlock(),e.createElementBlock("span",{key:3,class:e.normalizeClass(g.value)},[e.renderSlot(s.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(s.label),1)])],2)):e.createCommentVNode("",!0),i.value!=null&&s.isLoading?(e.openBlock(),e.createBlock(c.SpinnerIcon,{key:4,class:e.normalizeClass(o.value)},null,8,["class"])):typeof i.value=="string"?(e.openBlock(),e.createElementBlock("span",{key:5,class:e.normalizeClass(o.value)},e.toDisplayString(i.value),3)):i.value!=null?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i.value),{key:6,class:e.normalizeClass(o.value)},null,8,["class"])):e.createCommentVNode("",!0)],10,x))}});exports.OneButton=C;
@@ -1,5 +1,6 @@
1
- import { defineComponent as C, computed as o, openBlock as s, createElementBlock as u, normalizeClass as a, withModifiers as k, createBlock as p, toDisplayString as b, resolveDynamicComponent as m, createCommentVNode as g, renderSlot as B, createTextVNode as A } from "vue";
2
- import { S as v } from "../SpinnerIcon-516264ba.js";
1
+ import { defineComponent as C, computed as o, openBlock as s, createElementBlock as u, normalizeClass as r, withModifiers as k, createBlock as p, toDisplayString as b, resolveDynamicComponent as m, createCommentVNode as g, renderSlot as B, createTextVNode as A } from "vue";
2
+ import { S as v } from "../SpinnerIcon-74648c98.js";
3
+ import "../SpinnerIcon.vue_vue_type_style_index_0_lang-4ed993c7.js";
3
4
  import "../_plugin-vue_export-helper-dad06003.js";
4
5
  const S = {
5
6
  variant: {
@@ -90,17 +91,17 @@ const S = {
90
91
  send: [
91
92
  "rounded-full border-transparent bg-primary-base text-white hover:bg-primary-hover active:bg-primary-active p-[9px] focus:ring-primary-glow"
92
93
  ]
93
- }, I = (r = "primary", d = "md") => {
94
+ }, I = (a = "primary", d = "md") => {
94
95
  const n = [];
95
- return n.push(...L), n.push(...F[r] ?? []), r !== "touch" && r !== "mini" && r !== "edit" && r !== "send" && n.push(...z[d] ?? []), d === "xs" ? n.map(
96
+ return n.push(...L), n.push(...F[a] ?? []), a !== "touch" && a !== "mini" && a !== "edit" && a !== "send" && n.push(...z[d] ?? []), d === "xs" ? n.map(
96
97
  (e) => e.replace("rounded-10", "rounded-md").replace("font-semibold", "font-medium")
97
98
  ) : n;
98
- }, O = ["disabled", "title", "type"], _ = /* @__PURE__ */ C({
99
+ }, O = ["disabled", "title", "type"], E = /* @__PURE__ */ C({
99
100
  __name: "OneButton",
100
101
  props: S,
101
102
  emits: ["click"],
102
- setup(r, { emit: d }) {
103
- const n = d, e = r, y = () => {
103
+ setup(a, { emit: d }) {
104
+ const n = d, e = a, y = () => {
104
105
  n("click");
105
106
  }, l = o(() => e.icon), c = o(() => e.iconAfter), h = o(() => {
106
107
  const t = I(e.variant, e.size);
@@ -115,7 +116,7 @@ const S = {
115
116
  return e.variant === "edit" ? t.push("w-3.5 h-3.5") : e.variant === "send" ? t.push("w-5 h-5") : e.size === "xs" ? t.push("w-3.5 h-3.5") : e.size === "sm" ? t.push("w-3 h-3") : e.size === "lg" ? t.push("w-5 h-5") : t.push("w-4 h-4"), typeof e.iconClass == "string" ? t.push(e.iconClass) : e.iconClass instanceof Array && t.push(...e.iconClass), t;
116
117
  });
117
118
  return (t, j) => (s(), u("button", {
118
- class: a(h.value),
119
+ class: r(h.value),
119
120
  disabled: f.value,
120
121
  title: t.label,
121
122
  type: t.isSubmit ? "submit" : "button",
@@ -123,17 +124,17 @@ const S = {
123
124
  }, [
124
125
  l.value != null && t.isLoading ? (s(), p(v, {
125
126
  key: 0,
126
- class: a(i.value)
127
+ class: r(i.value)
127
128
  }, null, 8, ["class"])) : typeof l.value == "string" ? (s(), u("span", {
128
129
  key: 1,
129
- class: a(i.value)
130
+ class: r(i.value)
130
131
  }, b(l.value), 3)) : l.value != null ? (s(), p(m(l.value), {
131
132
  key: 2,
132
- class: a(i.value)
133
+ class: r(i.value)
133
134
  }, null, 8, ["class"])) : g("", !0),
134
135
  x.value ? (s(), u("span", {
135
136
  key: 3,
136
- class: a(w.value)
137
+ class: r(w.value)
137
138
  }, [
138
139
  B(t.$slots, "default", {}, () => [
139
140
  A(b(t.label), 1)
@@ -141,17 +142,17 @@ const S = {
141
142
  ], 2)) : g("", !0),
142
143
  c.value != null && t.isLoading ? (s(), p(v, {
143
144
  key: 4,
144
- class: a(i.value)
145
+ class: r(i.value)
145
146
  }, null, 8, ["class"])) : typeof c.value == "string" ? (s(), u("span", {
146
147
  key: 5,
147
- class: a(i.value)
148
+ class: r(i.value)
148
149
  }, b(c.value), 3)) : c.value != null ? (s(), p(m(c.value), {
149
150
  key: 6,
150
- class: a(i.value)
151
+ class: r(i.value)
151
152
  }, null, 8, ["class"])) : g("", !0)
152
153
  ], 10, O));
153
154
  }
154
155
  });
155
156
  export {
156
- _ as OneButton
157
+ E as OneButton
157
158
  };
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),r={buttons:{type:Array,default:[]},modelValue:{required:!1,type:[String,Number,Array,Boolean,Object,null]}},u={class:"flex text-xs space-x-0.5 bg-gray-100 p-0.5 rounded-md"},a=["onClick"],s=e.defineComponent({__name:"OneButtonGroup",props:r,emits:["update:modelValue"],setup(c,{emit:l}){const n=l;return(o,p)=>(e.openBlock(),e.createElementBlock("div",u,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.buttons,t=>(e.openBlock(),e.createElementBlock("button",{key:t.key,class:e.normalizeClass([{"bg-white":t.key==o.modelValue,"text-blue-600":t.key==o.modelValue},"h-[32px] w-full transition-all px-3 rounded-md hover:text-blue-600"]),onClick:i=>n("update:modelValue",t.key)},e.toDisplayString(t.label),11,a))),128))]))}});exports.OneButtonGroup=s;
@@ -0,0 +1,31 @@
1
+ import { defineComponent as s, openBlock as o, createElementBlock as l, Fragment as a, renderList as u, normalizeClass as p, toDisplayString as d } from "vue";
2
+ const i = {
3
+ buttons: {
4
+ type: Array,
5
+ default: []
6
+ },
7
+ modelValue: {
8
+ required: !1,
9
+ type: [String, Number, Array, Boolean, Object, null]
10
+ }
11
+ }, m = { class: "flex text-xs space-x-0.5 bg-gray-100 p-0.5 rounded-md" }, c = ["onClick"], x = /* @__PURE__ */ s({
12
+ __name: "OneButtonGroup",
13
+ props: i,
14
+ emits: ["update:modelValue"],
15
+ setup(y, { emit: r }) {
16
+ const n = r;
17
+ return (t, k) => (o(), l("div", m, [
18
+ (o(!0), l(a, null, u(t.buttons, (e) => (o(), l("button", {
19
+ key: e.key,
20
+ class: p([{
21
+ "bg-white": e.key == t.modelValue,
22
+ "text-blue-600": e.key == t.modelValue
23
+ }, "h-[32px] w-full transition-all px-3 rounded-md hover:text-blue-600"]),
24
+ onClick: (_) => n("update:modelValue", e.key)
25
+ }, d(e.label), 11, c))), 128))
26
+ ]));
27
+ }
28
+ });
29
+ export {
30
+ x as OneButtonGroup
31
+ };
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),p=require("../SpinnerIcon-ccb6f3fc.cjs"),f=require("../_plugin-vue_export-helper-f246444f.cjs");require("../SpinnerIcon.vue_vue_type_style_index_0_lang-0ea8fbf8.cjs");const m={color:{type:String,default:"blue"},textPosition:{type:String,default:"left"},isChecked:{type:Boolean,default:!0},isLoading:{required:!1,type:Boolean,default:!1},disabled:{required:!1,type:Boolean,default:!1},textOn:{type:String,default:""},textOff:{type:String,default:""},textClass:{type:[String,Array]}},k={key:0,class:"mr-2 text-gray-600 text-sm font-medium"},h={key:1,class:"checkmark-tick absolute inset-0 w-full h-full",viewBox:"0 0 24 24",fill:"none",stroke:"white","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"},b={key:1,class:"ml-2 text-gray-600 text-sm font-medium"},g=e.defineComponent({__name:"OneCheckbox",props:m,emits:["change"],setup(r,{emit:s}){const t=r,o=e.ref(t.isChecked),a=s,c=e.computed(()=>{if(o.value)switch(t.color){case"green":return"#86c94c";case"blue":return"#2196f3";case"red":return"#f44336";case"yellow":return"#ffeb3b";default:return"#86c94c"}else return"#fefefe"}),i=e.computed(()=>t.disabled),u=l=>{const n=l.target;o.value=n.checked,a("change",o.value)};return(l,n)=>(e.openBlock(),e.createElementBlock("label",{class:e.normalizeClass([[i.value?"disabled opacity-50 pointer-events-none":""],"checkbox inline-flex items-center cursor-pointer mb-3 text-lg"])},[e.withDirectives(e.createElementVNode("input",{type:"checkbox","onUpdate:modelValue":n[0]||(n[0]=d=>o.value=d),onChange:u,class:"hidden"},null,544),[[e.vModelCheckbox,o.value]]),t.textPosition==="left"?(e.openBlock(),e.createElementBlock("span",k,e.toDisplayString(o.value?t.textOn:t.textOff),1)):e.createCommentVNode("",!0),e.createElementVNode("span",{class:"checkmark h-5 w-5 flex-shrink-0 border border-gray-300 rounded transition-all duration-300 relative hover:border-2 hover:border-gray-500",style:e.normalizeStyle({backgroundColor:c.value})},[e.createElementVNode("div",null,[l.isLoading?(e.openBlock(),e.createBlock(p.SpinnerIcon,{key:0,class:"absolute w-3 h-3 text-black left-1/2 top-1/2 -ml-1.5 -mt-1.5"})):!l.isLoading&&o.value?(e.openBlock(),e.createElementBlock("svg",h,[...n[1]||(n[1]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)])],4),t.textPosition==="right"?(e.openBlock(),e.createElementBlock("span",b,e.toDisplayString(o.value?t.textOn:t.textOff),1)):e.createCommentVNode("",!0)],2))}});const x=f._export_sfc(g,[["__scopeId","data-v-0c95be43"]]);exports.OneCheckbox=x;
@@ -0,0 +1,124 @@
1
+ import { defineComponent as x, ref as b, computed as i, openBlock as n, createElementBlock as r, normalizeClass as y, withDirectives as g, createElementVNode as s, vModelCheckbox as v, toDisplayString as c, createCommentVNode as a, normalizeStyle as _, createBlock as C } from "vue";
2
+ import { S as w } from "../SpinnerIcon-74648c98.js";
3
+ import { _ as O } from "../_plugin-vue_export-helper-dad06003.js";
4
+ import "../SpinnerIcon.vue_vue_type_style_index_0_lang-4ed993c7.js";
5
+ const S = {
6
+ color: {
7
+ type: String,
8
+ default: "blue"
9
+ },
10
+ // size: {
11
+ // type: String as PropType<CheckboxSizeType>,
12
+ // default: 'sm'
13
+ // },
14
+ textPosition: {
15
+ type: String,
16
+ default: "left"
17
+ },
18
+ isChecked: {
19
+ type: Boolean,
20
+ default: !0
21
+ },
22
+ isLoading: {
23
+ required: !1,
24
+ type: Boolean,
25
+ default: !1
26
+ },
27
+ disabled: {
28
+ required: !1,
29
+ type: Boolean,
30
+ default: !1
31
+ },
32
+ textOn: {
33
+ type: String,
34
+ default: ""
35
+ },
36
+ textOff: {
37
+ type: String,
38
+ default: ""
39
+ },
40
+ textClass: {
41
+ type: [String, Array]
42
+ }
43
+ // iconOn: {
44
+ // type: [Function, Object] as PropType<SwitchIconType>
45
+ // },
46
+ // iconOff: {
47
+ // type: [Function, Object] as PropType<SwitchIconType>
48
+ // },
49
+ // iconClass: {
50
+ // type: [String, Array] as PropType<string|string[]>
51
+ // },
52
+ }, B = {
53
+ key: 0,
54
+ class: "mr-2 text-gray-600 text-sm font-medium"
55
+ }, P = {
56
+ key: 1,
57
+ class: "checkmark-tick absolute inset-0 w-full h-full",
58
+ viewBox: "0 0 24 24",
59
+ fill: "none",
60
+ stroke: "white",
61
+ "stroke-width": "3",
62
+ "stroke-linecap": "round",
63
+ "stroke-linejoin": "round"
64
+ }, D = {
65
+ key: 1,
66
+ class: "ml-2 text-gray-600 text-sm font-medium"
67
+ }, L = /* @__PURE__ */ x({
68
+ __name: "OneCheckbox",
69
+ props: S,
70
+ emits: ["change"],
71
+ setup(d, { emit: u }) {
72
+ const e = d, t = b(e.isChecked), f = u, p = i(() => {
73
+ if (t.value)
74
+ switch (e.color) {
75
+ case "green":
76
+ return "#86c94c";
77
+ case "blue":
78
+ return "#2196f3";
79
+ case "red":
80
+ return "#f44336";
81
+ case "yellow":
82
+ return "#ffeb3b";
83
+ default:
84
+ return "#86c94c";
85
+ }
86
+ else
87
+ return "#fefefe";
88
+ }), m = i(() => e.disabled), h = (l) => {
89
+ const o = l.target;
90
+ t.value = o.checked, f("change", t.value);
91
+ };
92
+ return (l, o) => (n(), r("label", {
93
+ class: y([[m.value ? "disabled opacity-50 pointer-events-none" : ""], "checkbox inline-flex items-center cursor-pointer mb-3 text-lg"])
94
+ }, [
95
+ g(s("input", {
96
+ type: "checkbox",
97
+ "onUpdate:modelValue": o[0] || (o[0] = (k) => t.value = k),
98
+ onChange: h,
99
+ class: "hidden"
100
+ }, null, 544), [
101
+ [v, t.value]
102
+ ]),
103
+ e.textPosition === "left" ? (n(), r("span", B, c(t.value ? e.textOn : e.textOff), 1)) : a("", !0),
104
+ s("span", {
105
+ class: "checkmark h-5 w-5 flex-shrink-0 border border-gray-300 rounded transition-all duration-300 relative hover:border-2 hover:border-gray-500",
106
+ style: _({ backgroundColor: p.value })
107
+ }, [
108
+ s("div", null, [
109
+ l.isLoading ? (n(), C(w, {
110
+ key: 0,
111
+ class: "absolute w-3 h-3 text-black left-1/2 top-1/2 -ml-1.5 -mt-1.5"
112
+ })) : !l.isLoading && t.value ? (n(), r("svg", P, [...o[1] || (o[1] = [
113
+ s("polyline", { points: "20 6 9 17 4 12" }, null, -1)
114
+ ])])) : a("", !0)
115
+ ])
116
+ ], 4),
117
+ e.textPosition === "right" ? (n(), r("span", D, c(t.value ? e.textOn : e.textOff), 1)) : a("", !0)
118
+ ], 2));
119
+ }
120
+ });
121
+ const I = /* @__PURE__ */ O(L, [["__scopeId", "data-v-0c95be43"]]);
122
+ export {
123
+ I as OneCheckbox
124
+ };
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),d=require("../_plugin-vue_export-helper-f246444f.cjs"),v=e.defineComponent({__name:"OneCollapse",props:{blockClass:{},titleClass:{},defaultOpen:{type:Boolean}},setup(n){const r=n,{blockClass:a,titleClass:c,defaultOpen:l}=e.toRefs(r),i=e.ref(null),o=e.ref((l==null?void 0:l.value)??!1),u=()=>{o.value=!o.value},p=t=>{const s=t;s.style.height="0"},h=t=>{const s=t;s.style.height=`${t.scrollHeight}px`,s.style.transition="height 0.3s ease"},_=t=>{const s=t;s.style.height=`${t.scrollHeight}px`,e.nextTick(()=>{s.style.height="0",s.style.transition="height 0.3s ease"})};return(t,s)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(e.unref(a))},[e.createElementVNode("div",{onClick:u,class:e.normalizeClass(e.unref(c))},[e.renderSlot(t.$slots,"title",{isOpen:o.value},void 0,!0)],2),e.createVNode(e.Transition,{name:"accordion",onBeforeEnter:p,onEnter:h,onLeave:_},{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",{ref_key:"content",ref:i},[e.renderSlot(t.$slots,"default",{},void 0,!0)],512),[[e.vShow,o.value]])]),_:3})],2))}});const f=d._export_sfc(v,[["__scopeId","data-v-525e3430"]]);exports.OneCollapse=f;
@@ -0,0 +1,58 @@
1
+ import { defineComponent as g, toRefs as C, ref as n, openBlock as y, createElementBlock as E, normalizeClass as l, unref as a, createElementVNode as c, renderSlot as i, createVNode as k, Transition as x, withCtx as O, withDirectives as B, vShow as $, nextTick as b } from "vue";
2
+ import { _ as w } from "../_plugin-vue_export-helper-dad06003.js";
3
+ const H = /* @__PURE__ */ g({
4
+ __name: "OneCollapse",
5
+ props: {
6
+ blockClass: {},
7
+ titleClass: {},
8
+ defaultOpen: { type: Boolean }
9
+ },
10
+ setup(r) {
11
+ const p = r, { blockClass: h, titleClass: _, defaultOpen: o } = C(p), v = n(null), s = n((o == null ? void 0 : o.value) ?? !1), d = () => {
12
+ s.value = !s.value;
13
+ }, u = (e) => {
14
+ const t = e;
15
+ t.style.height = "0";
16
+ }, f = (e) => {
17
+ const t = e;
18
+ t.style.height = `${e.scrollHeight}px`, t.style.transition = "height 0.3s ease";
19
+ }, m = (e) => {
20
+ const t = e;
21
+ t.style.height = `${e.scrollHeight}px`, b(() => {
22
+ t.style.height = "0", t.style.transition = "height 0.3s ease";
23
+ });
24
+ };
25
+ return (e, t) => (y(), E("div", {
26
+ class: l(a(h))
27
+ }, [
28
+ c("div", {
29
+ onClick: d,
30
+ class: l(a(_))
31
+ }, [
32
+ i(e.$slots, "title", { isOpen: s.value }, void 0, !0)
33
+ ], 2),
34
+ k(x, {
35
+ name: "accordion",
36
+ onBeforeEnter: u,
37
+ onEnter: f,
38
+ onLeave: m
39
+ }, {
40
+ default: O(() => [
41
+ B(c("div", {
42
+ ref_key: "content",
43
+ ref: v
44
+ }, [
45
+ i(e.$slots, "default", {}, void 0, !0)
46
+ ], 512), [
47
+ [$, s.value]
48
+ ])
49
+ ]),
50
+ _: 3
51
+ })
52
+ ], 2));
53
+ }
54
+ });
55
+ const T = /* @__PURE__ */ w(H, [["__scopeId", "data-v-525e3430"]]);
56
+ export {
57
+ T as OneCollapse
58
+ };