readytech-ui-library-v2 1.0.31 → 1.0.33

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.
@@ -15955,12 +15955,12 @@ const vh = /* @__PURE__ */ ce(dh, [["render", fh], ["__scopeId", "data-v-61d3c99
15955
15955
  id() {
15956
15956
  return `rt-input-${this.uid}`;
15957
15957
  },
15958
- errorId() {
15959
- return this.errorMessages.length ? `error-${this.id}` : null;
15960
- },
15961
- hintId() {
15962
- return this.hint ? `hint-${this.id}` : null;
15963
- },
15958
+ // errorId() {
15959
+ // return this.errorMessages.length ? `error-${this.id}` : null;
15960
+ // },
15961
+ // hintId() {
15962
+ // return this.hint ? `hint-${this.id}` : null;
15963
+ // },
15964
15964
  computedAriaDescribedby() {
15965
15965
  return [this.hintId, this.errorId].filter(Boolean).join(" ") || null;
15966
15966
  }
@@ -15973,13 +15973,14 @@ const vh = /* @__PURE__ */ ce(dh, [["render", fh], ["__scopeId", "data-v-61d3c99
15973
15973
  }, hh = {
15974
15974
  class: "rt-input",
15975
15975
  role: "main"
15976
- }, gh = ["id"];
15977
- function yh(e, n, t, l, a, i) {
15976
+ };
15977
+ function gh(e, n, t, l, a, i) {
15978
15978
  return D(), xe("div", hh, [
15979
15979
  s(jt, N(i.inputProps, {
15980
15980
  modelValue: i.inputValue,
15981
15981
  "onUpdate:modelValue": n[0] || (n[0] = (o) => i.inputValue = o),
15982
15982
  id: i.id,
15983
+ hint: t.hint,
15983
15984
  "aria-label": t.label || "Input field",
15984
15985
  "aria-describedby": i.computedAriaDescribedby,
15985
15986
  "aria-invalid": t.error ? "true" : "false",
@@ -15991,15 +15992,10 @@ function yh(e, n, t, l, a, i) {
15991
15992
  clearable: "",
15992
15993
  autocomplete: t.autocomplete,
15993
15994
  "onClick:clear": i.handleClear
15994
- }), null, 16, ["modelValue", "id", "aria-label", "aria-describedby", "aria-invalid", "placeholder", "disabled", "error", "error-messages", "prepend-icon", "autocomplete", "onClick:clear"]),
15995
- t.hint ? (D(), xe("p", {
15996
- key: 0,
15997
- id: i.hintId,
15998
- class: "hint"
15999
- }, ue(t.hint), 9, gh)) : be("", !0)
15995
+ }), null, 16, ["modelValue", "id", "hint", "aria-label", "aria-describedby", "aria-invalid", "placeholder", "disabled", "error", "error-messages", "prepend-icon", "autocomplete", "onClick:clear"])
16000
15996
  ]);
16001
15997
  }
16002
- const Ii = /* @__PURE__ */ ce(mh, [["render", yh], ["__scopeId", "data-v-5e7869ad"]]), bh = {
15998
+ const Ii = /* @__PURE__ */ ce(mh, [["render", gh], ["__scopeId", "data-v-4b1353d9"]]), yh = {
16003
15999
  name: "RtConfirmEdit",
16004
16000
  components: {
16005
16001
  RtInput: Ii,
@@ -16038,8 +16034,8 @@ const Ii = /* @__PURE__ */ ce(mh, [["render", yh], ["__scopeId", "data-v-5e7869a
16038
16034
  this.isEditing = !1, this.currentValue = this.value;
16039
16035
  }
16040
16036
  }
16041
- }, kh = { class: "actions" };
16042
- function Sh(e, n, t, l, a, i) {
16037
+ }, bh = { class: "actions" };
16038
+ function kh(e, n, t, l, a, i) {
16043
16039
  const o = Ee("RtInput"), r = Ee("RtButton"), u = Ee("RtIcon");
16044
16040
  return D(), U(Sn, {
16045
16041
  outlined: "",
@@ -16057,7 +16053,7 @@ function Sh(e, n, t, l, a, i) {
16057
16053
  dense: "",
16058
16054
  class: "edit-field"
16059
16055
  }, null, 8, ["modelValue", "label"]),
16060
- Je("div", kh, [
16056
+ Je("div", bh, [
16061
16057
  s(r, {
16062
16058
  color: "primary",
16063
16059
  small: "",
@@ -16098,7 +16094,7 @@ function Sh(e, n, t, l, a, i) {
16098
16094
  _: 1
16099
16095
  });
16100
16096
  }
16101
- const Ch = /* @__PURE__ */ ce(bh, [["render", Sh], ["__scopeId", "data-v-cc22a96f"]]), ph = {
16097
+ const Sh = /* @__PURE__ */ ce(yh, [["render", kh], ["__scopeId", "data-v-cc22a96f"]]), Ch = {
16102
16098
  name: "RtDateInput",
16103
16099
  props: {
16104
16100
  modelValue: {
@@ -16117,68 +16113,122 @@ const Ch = /* @__PURE__ */ ce(bh, [["render", Sh], ["__scopeId", "data-v-cc22a96
16117
16113
  type: String,
16118
16114
  default: "Select Date"
16119
16115
  },
16116
+ hint: {
16117
+ type: String,
16118
+ default: "dd/mm/yyyy"
16119
+ },
16120
16120
  multiple: {
16121
16121
  type: Boolean,
16122
16122
  default: !1
16123
16123
  }
16124
16124
  },
16125
+ computed: {
16126
+ inputValue: {
16127
+ get() {
16128
+ return this.modelValue;
16129
+ },
16130
+ set(e) {
16131
+ this.$emit("update:modelValue", e);
16132
+ }
16133
+ },
16134
+ inputProps() {
16135
+ return { ...this.$props };
16136
+ },
16137
+ id() {
16138
+ return `rt-date-input-${this.uid}`;
16139
+ },
16140
+ // errorId() {
16141
+ // return this.errorMessages.length ? `error-${this.id}` : null;
16142
+ // },
16143
+ computedAriaDescribedby() {
16144
+ return [this.hintId, this.errorId].filter(Boolean).join(" ") || null;
16145
+ }
16146
+ },
16125
16147
  emits: ["update:modelValue"],
16126
16148
  setup(e, { emit: n }) {
16127
- const t = Y(!1), l = Y(e.modelValue), a = g(() => l.value ? new Date(l.value).toLocaleDateString() : ""), i = (o) => {
16128
- n("update:modelValue", o), t.value = !1;
16129
- };
16130
- return ne(
16149
+ const t = Y(!1), l = Y(e.modelValue);
16150
+ ne(
16131
16151
  () => e.modelValue,
16132
16152
  (o) => {
16133
- l.value = o;
16153
+ l.value = o ? new Date(o) : null;
16154
+ }
16155
+ );
16156
+ const a = g({
16157
+ get() {
16158
+ return l.value ? l.value.toLocaleDateString() : "";
16159
+ },
16160
+ set(o) {
16161
+ const r = new Date(o);
16162
+ isNaN(r) || (l.value = r, n("update:modelValue", r));
16134
16163
  }
16135
- ), {
16164
+ });
16165
+ return {
16136
16166
  menu: t,
16137
16167
  date: l,
16138
16168
  formattedDate: a,
16139
- onDateSelect: i
16169
+ onDateSelect: (o) => {
16170
+ n("update:modelValue", o), t.value = !1;
16171
+ }
16140
16172
  };
16141
16173
  }
16174
+ }, ph = {
16175
+ class: "rt-date-input",
16176
+ role: "main"
16142
16177
  };
16143
16178
  function wh(e, n, t, l, a, i) {
16144
- return D(), U(Wt, {
16145
- modelValue: l.menu,
16146
- "onUpdate:modelValue": n[2] || (n[2] = (o) => l.menu = o),
16147
- transition: "scale-transition",
16148
- "close-on-content-click": !1,
16149
- "max-width": "290px",
16150
- "min-width": "290px",
16151
- "aria-haspopup": "true",
16152
- "aria-expanded": l.menu.toString()
16153
- }, {
16154
- activator: H(({ props: o }) => [
16155
- s(jt, N(o, {
16156
- "prepend-inner-icon": "mdi-calendar",
16157
- modelValue: l.formattedDate,
16158
- "onUpdate:modelValue": n[0] || (n[0] = (r) => l.formattedDate = r),
16159
- label: t.label,
16160
- readonly: "",
16161
- "aria-live": "polite",
16162
- role: "textbox"
16163
- }), null, 16, ["modelValue", "label"])
16164
- ]),
16165
- default: H(() => [
16166
- s(is, {
16167
- modelValue: l.date,
16168
- "onUpdate:modelValue": [
16169
- n[1] || (n[1] = (o) => l.date = o),
16170
- l.onDateSelect
16171
- ],
16172
- min: t.min,
16173
- max: t.max,
16174
- multiple: t.multiple,
16175
- "aria-label": "Date Picker"
16176
- }, null, 8, ["modelValue", "onUpdate:modelValue", "min", "max", "multiple"])
16177
- ]),
16178
- _: 1
16179
- }, 8, ["modelValue", "aria-expanded"]);
16179
+ return D(), xe("div", ph, [
16180
+ s(Wt, {
16181
+ modelValue: l.menu,
16182
+ "onUpdate:modelValue": n[2] || (n[2] = (o) => l.menu = o),
16183
+ transition: "scale-transition",
16184
+ "close-on-content-click": !1,
16185
+ "max-width": "290px",
16186
+ "min-width": "290px",
16187
+ "aria-haspopup": "true",
16188
+ "aria-expanded": l.menu.toString()
16189
+ }, {
16190
+ activator: H(({ props: o }) => [
16191
+ s(jt, N(o, {
16192
+ modelValue: l.formattedDate,
16193
+ "onUpdate:modelValue": n[0] || (n[0] = (r) => l.formattedDate = r),
16194
+ "prepend-inner-icon": "mdi-calendar",
16195
+ id: i.id,
16196
+ hint: t.hint,
16197
+ "aria-label": t.label || "Date input field",
16198
+ "aria-describedby": i.computedAriaDescribedby,
16199
+ "aria-invalid": e.error ? "true" : "false",
16200
+ placeholder: e.placeholder,
16201
+ disabled: e.disabled,
16202
+ error: e.error,
16203
+ "error-messages": e.errorMessages,
16204
+ "prepend-icon": e.prependIcon,
16205
+ clearable: "",
16206
+ autocomplete: e.autocomplete,
16207
+ "onClick:clear": e.handleClear,
16208
+ label: t.label,
16209
+ readonly: "",
16210
+ "aria-live": "polite",
16211
+ role: "textbox"
16212
+ }), null, 16, ["modelValue", "id", "hint", "aria-label", "aria-describedby", "aria-invalid", "placeholder", "disabled", "error", "error-messages", "prepend-icon", "autocomplete", "onClick:clear", "label"])
16213
+ ]),
16214
+ default: H(() => [
16215
+ s(is, {
16216
+ modelValue: l.date,
16217
+ "onUpdate:modelValue": [
16218
+ n[1] || (n[1] = (o) => l.date = o),
16219
+ l.onDateSelect
16220
+ ],
16221
+ min: t.min,
16222
+ max: t.max,
16223
+ multiple: t.multiple,
16224
+ "aria-label": "Date Picker"
16225
+ }, null, 8, ["modelValue", "onUpdate:modelValue", "min", "max", "multiple"])
16226
+ ]),
16227
+ _: 1
16228
+ }, 8, ["modelValue", "aria-expanded"])
16229
+ ]);
16180
16230
  }
16181
- const xh = /* @__PURE__ */ ce(ph, [["render", wh]]), Vh = {
16231
+ const xh = /* @__PURE__ */ ce(Ch, [["render", wh]]), Vh = {
16182
16232
  name: "RtDatePicker",
16183
16233
  props: {
16184
16234
  color: {
@@ -24270,7 +24320,7 @@ function Bk(e, n, t, l, a, i) {
24270
24320
  }
24271
24321
  const Rk = /* @__PURE__ */ ce(Ak, [["render", Bk]]), Ek = {
24272
24322
  install: (e, n) => {
24273
- e.component("RtAlert", Rc), e.component("RtAvatar", Uc), e.component("RtBadge", Yc), e.component("RtBottomNavigation", ad), e.component("RtBottomSheet", $d), e.component("RtBreadcrumbs", Jd), e.component("RtButton", Lt), e.component("RtCalendar", em), e.component("RtCard", lm), e.component("RtCheckbox", om), e.component("RtColorPicker", Jm), e.component("RtComboBox", vh), e.component("RtConfirmEdit", Ch), e.component("RtDateInput", xh), e.component("RtDatePicker", Ih), e.component("RtDialog", Ah), e.component("RtDivider", Dh), e.component("RtExpansionPanel", Lh), e.component("RtFileInput", $h), e.component("RtFloatingButton", Wh), e.component("RtForm", Jh), e.component("RtGrid", tg), e.component("RtHeader", Ys), e.component("RtHover", kg), e.component("RtIcon", Mn), e.component("RtImage", wr), e.component("RtInfiniteScroll", Tg), e.component("RtInput", Ii), e.component("RtList", Bg), e.component("RtMenu", Eg), e.component("RtNavigationDrawer", Kg), e.component("RtOtp", Jg), e.component("RtOverlay", ey), e.component("RtPage", ly), e.component("RtPagination", cy), e.component("RtParallax", gy), e.component("RtPopover", Sy), e.component("RtProgressCircle", wy), e.component("RtRadioGroup", By), e.component("RtRangeSlider", Ly), e.component("RtRatings", $y), e.component("RtSelect", Ws), e.component("RtSelectAutocomplete", Yy), e.component("RtSheet", Xy), e.component("RtSlider", Qy), e.component("RtSnackbar", lb), e.component("RtSpeedDial", ub), e.component("RtStepper", fb), e.component("RtSwitch", yb), e.component("RtSystemBar", wb), e.component("RtTable", Tb), e.component("RtTabs", Fb), e.component("RtTextArea", Ub), e.component("RtTimeline", Jb), e.component("RtTimePicker", ik), e.component("RtTimePickerUI", sk), e.component("RtToolBar", dk), e.component("RtTreeview", mk), e.component("RtContainer", yk), e.component("RtTooltip", Sk), e.component("RtHorizontalRule", xk), e.component("RtButtonGroup", Pk), e.component("RtDialogDynamic", Rk);
24323
+ e.component("RtAlert", Rc), e.component("RtAvatar", Uc), e.component("RtBadge", Yc), e.component("RtBottomNavigation", ad), e.component("RtBottomSheet", $d), e.component("RtBreadcrumbs", Jd), e.component("RtButton", Lt), e.component("RtCalendar", em), e.component("RtCard", lm), e.component("RtCheckbox", om), e.component("RtColorPicker", Jm), e.component("RtComboBox", vh), e.component("RtConfirmEdit", Sh), e.component("RtDateInput", xh), e.component("RtDatePicker", Ih), e.component("RtDialog", Ah), e.component("RtDivider", Dh), e.component("RtExpansionPanel", Lh), e.component("RtFileInput", $h), e.component("RtFloatingButton", Wh), e.component("RtForm", Jh), e.component("RtGrid", tg), e.component("RtHeader", Ys), e.component("RtHover", kg), e.component("RtIcon", Mn), e.component("RtImage", wr), e.component("RtInfiniteScroll", Tg), e.component("RtInput", Ii), e.component("RtList", Bg), e.component("RtMenu", Eg), e.component("RtNavigationDrawer", Kg), e.component("RtOtp", Jg), e.component("RtOverlay", ey), e.component("RtPage", ly), e.component("RtPagination", cy), e.component("RtParallax", gy), e.component("RtPopover", Sy), e.component("RtProgressCircle", wy), e.component("RtRadioGroup", By), e.component("RtRangeSlider", Ly), e.component("RtRatings", $y), e.component("RtSelect", Ws), e.component("RtSelectAutocomplete", Yy), e.component("RtSheet", Xy), e.component("RtSlider", Qy), e.component("RtSnackbar", lb), e.component("RtSpeedDial", ub), e.component("RtStepper", fb), e.component("RtSwitch", yb), e.component("RtSystemBar", wb), e.component("RtTable", Tb), e.component("RtTabs", Fb), e.component("RtTextArea", Ub), e.component("RtTimeline", Jb), e.component("RtTimePicker", ik), e.component("RtTimePickerUI", sk), e.component("RtToolBar", dk), e.component("RtTreeview", mk), e.component("RtContainer", yk), e.component("RtTooltip", Sk), e.component("RtHorizontalRule", xk), e.component("RtButtonGroup", Pk), e.component("RtDialogDynamic", Rk);
24274
24324
  }
24275
24325
  };
24276
24326
  export {