@opens/ui 1.1.0 → 1.1.1

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.
@@ -13977,10 +13977,13 @@ const WA = /* @__PURE__ */ K({
13977
13977
  props: {
13978
13978
  center: Boolean,
13979
13979
  segment: Boolean,
13980
- small: Boolean
13980
+ small: Boolean,
13981
+ defaultTab: {
13982
+ type: String
13983
+ }
13981
13984
  },
13982
13985
  setup(e) {
13983
- const t = Ke(), n = Object.keys(t), r = G(n[0]), a = e, s = p(() => a.segment ? "yu-bg-gray-100 yu-rounded-md" : "yu-border-b"), o = p(() => a.segment ? "yu-p-2 yu-transition-all duration-200 yu-group yu-rounded-md yu-w-full data-[state=active]:yu-bg-white data-[state=active]:yu-shadow" : a.small ? "yu-p-2 yu-border-b yu-border-transparent yu-transition-all duration-200 yu-group data-[state=active]:yu-border-b-primary" : "yu-p-2 yu-px-4 yu-border-b yu-border-transparent yu-transition-all duration-200 yu-group data-[state=active]:yu-border-b-primary");
13986
+ const t = e, n = Ke(), r = Object.keys(n), a = G(t.defaultTab ?? r[0]), s = p(() => t.segment ? "yu-bg-gray-100 yu-rounded-md" : "yu-border-b"), o = p(() => t.segment ? "yu-p-2 yu-transition-all duration-200 yu-group yu-rounded-md yu-w-full data-[state=active]:yu-bg-white data-[state=active]:yu-shadow" : t.small ? "yu-p-2 yu-border-b-2 yu-border-transparent yu-transition-all duration-200 yu-group data-[state=active]:yu-border-b-primary" : "yu-p-2 yu-px-4 yu-border-b-2 yu-border-transparent yu-transition-all duration-200 yu-group data-[state=active]:yu-border-b-primary");
13984
13987
  return (i, l) => (m(), j(me, {
13985
13988
  col: "",
13986
13989
  "gap-none": ""
@@ -13993,15 +13996,15 @@ const WA = /* @__PURE__ */ K({
13993
13996
  "padding-sm": e.segment
13994
13997
  }, {
13995
13998
  default: $(() => [
13996
- (m(!0), D(ke, null, Ie(_(n), (u) => (m(), D("button", {
13999
+ (m(!0), D(ke, null, Ie(_(r), (u) => (m(), D("button", {
13997
14000
  key: u,
13998
14001
  class: P([o.value]),
13999
- "data-state": r.value === u ? "active" : "inactive",
14000
- onClick: (c) => r.value = u
14002
+ "data-state": a.value === u ? "active" : "inactive",
14003
+ onClick: (c) => a.value = u
14001
14004
  }, [
14002
14005
  Y(he, {
14003
- class: P(["group-hover:!yu-text-primary yu-transition-colors duration-200", { "!yu-text-primary": r.value === u }]),
14004
- gray: r.value !== u,
14006
+ class: P(["group-hover:!yu-text-primary yu-transition-colors duration-200", { "!yu-text-primary": a.value === u }]),
14007
+ gray: a.value !== u,
14005
14008
  small: e.small,
14006
14009
  medium: ""
14007
14010
  }, {
@@ -14014,7 +14017,7 @@ const WA = /* @__PURE__ */ K({
14014
14017
  ]),
14015
14018
  _: 1
14016
14019
  }, 8, ["class", "center", "padding-sm"]),
14017
- (m(), j(us(_(t)[r.value]), { key: r.value }))
14020
+ (m(), j(us(_(n)[a.value]), { key: a.value }))
14018
14021
  ]),
14019
14022
  _: 1
14020
14023
  }));