@appmax_npm/ds-prime 1.0.0-alpha.101 → 1.0.0-alpha.102

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.
@@ -1,6 +1,6 @@
1
1
  import { DefineComponent } from 'vue';
2
2
 
3
- export type AmNotificationVariant = "danger" | "warn" | "success" | "info";
3
+ export type AmNotificationVariant = "danger" | "warn" | "success" | "info" | "neutral";
4
4
 
5
5
  export interface AmNotificationProps {
6
6
  title?: string;
@@ -9,6 +9,7 @@ export interface AmNotificationProps {
9
9
  variant?: AmNotificationVariant;
10
10
  dataTestPrefix?: string;
11
11
  class?: string;
12
+ card?: boolean;
12
13
  }
13
14
 
14
15
  export interface AmNotificationSlots {}
@@ -1,48 +1,56 @@
1
- import { defineComponent as p, computed as _, openBlock as a, createElementBlock as r, normalizeClass as v, unref as w, createElementVNode as o, createVNode as h, createBlock as c, withCtx as d, createTextVNode as l, toDisplayString as m, createCommentVNode as n, renderSlot as f } from "vue";
1
+ import { defineComponent as g, computed as _, openBlock as a, createElementBlock as n, normalizeClass as v, unref as w, createElementVNode as i, createVNode as b, createBlock as c, withCtx as d, createTextVNode as l, toDisplayString as f, createCommentVNode as r, renderSlot as m } from "vue";
2
2
  import { _ as u } from "../AmText.vue_vue_type_script_setup_true_lang-BLpqo8Ry.js";
3
- import { _ as k } from "../AmIcon.vue_vue_type_script_setup_true_lang-DkJ2sUVG.js";
3
+ import { _ as x } from "../AmIcon.vue_vue_type_script_setup_true_lang-DkJ2sUVG.js";
4
4
  import { cva as N } from "class-variance-authority";
5
- import { twMerge as $ } from "tailwind-merge";
6
- const x = N("am-notification flex rounded items-center p-4 gap-4", {
5
+ import { twMerge as h } from "tailwind-merge";
6
+ import { _ as k } from "../_plugin-vue_export-helper-CHgC5LLL.js";
7
+ const $ = N("am-notification flex rounded-md items-center p-4 gap-4 bg-surface-100 text-color", {
7
8
  variants: {
8
9
  variant: {
9
10
  warn: "bg-warning-100 text-warn-800",
10
11
  danger: "bg-danger-100 text-danger-800",
11
12
  info: "bg-primary-100 text-primary-800",
12
- success: "bg-success-100 text-success-800"
13
+ success: "bg-success-100 text-success-800",
14
+ neutral: ""
15
+ },
16
+ card: {
17
+ true: "am-notification--card",
18
+ false: ""
13
19
  }
14
20
  }
15
- }), b = (s, i) => $(x(s), i), y = { class: "pt-1.5 mb-auto" }, P = { class: "sm:flex flex-grow items-center grid gap-4" }, C = { class: "flex-grow" }, T = {
21
+ }), y = (s, o) => h($(s), o), P = { class: "pt-1.5 mb-auto" }, C = { class: "sm:flex flex-grow items-center grid gap-4" }, T = { class: "flex-grow" }, V = {
16
22
  key: 0,
17
23
  class: "flex-shrink-0"
18
- }, V = { name: "AmNotification" }, D = /* @__PURE__ */ p({
19
- ...V,
24
+ }, B = { name: "AmNotification" }, A = /* @__PURE__ */ g({
25
+ ...B,
20
26
  props: {
21
27
  title: {},
22
28
  message: {},
23
29
  icon: {},
24
30
  variant: { default: "warn" },
25
31
  dataTestPrefix: { default: "am-notification" },
26
- class: {}
32
+ class: {},
33
+ card: { type: Boolean }
27
34
  },
28
35
  setup(s) {
29
- const i = {
36
+ const o = {
30
37
  danger: "error",
31
38
  warn: "warning",
32
39
  success: "check",
33
- info: "info"
34
- }, e = s, g = _(() => e.icon || i[e.variant] || "warning");
35
- return (t, B) => (a(), r("div", {
36
- class: v(w(b)(e, e.class))
40
+ info: "info",
41
+ neutral: "info"
42
+ }, e = s, p = _(() => e.icon || o[e.variant] || "warning");
43
+ return (t, E) => (a(), n("div", {
44
+ class: v(w(y)(e, e.class))
37
45
  }, [
38
- o("div", y, [
39
- h(k, {
40
- icon: g.value,
46
+ i("div", P, [
47
+ b(x, {
48
+ icon: p.value,
41
49
  "data-test": `${t.dataTestPrefix}-icon`
42
50
  }, null, 8, ["icon", "data-test"])
43
51
  ]),
44
- o("div", P, [
45
- o("div", C, [
52
+ i("div", C, [
53
+ i("div", T, [
46
54
  t.title ? (a(), c(u, {
47
55
  key: 0,
48
56
  variant: "subtitle",
@@ -50,28 +58,28 @@ const x = N("am-notification flex rounded items-center p-4 gap-4", {
50
58
  "is-strong": ""
51
59
  }, {
52
60
  default: d(() => [
53
- l(m(t.title), 1)
61
+ l(f(t.title), 1)
54
62
  ]),
55
63
  _: 1
56
- }, 8, ["data-test"])) : n("", !0),
64
+ }, 8, ["data-test"])) : r("", !0),
57
65
  t.message ? (a(), c(u, {
58
66
  key: 1,
59
67
  "data-test": `${t.dataTestPrefix}-message`
60
68
  }, {
61
69
  default: d(() => [
62
- l(m(t.message), 1)
70
+ l(f(t.message), 1)
63
71
  ]),
64
72
  _: 1
65
- }, 8, ["data-test"])) : n("", !0),
66
- f(t.$slots, "default")
73
+ }, 8, ["data-test"])) : r("", !0),
74
+ m(t.$slots, "default", {}, void 0, !0)
67
75
  ]),
68
- t.$slots.action ? (a(), r("div", T, [
69
- f(t.$slots, "action")
70
- ])) : n("", !0)
76
+ t.$slots.action ? (a(), n("div", V, [
77
+ m(t.$slots, "action", {}, void 0, !0)
78
+ ])) : r("", !0)
71
79
  ])
72
80
  ], 2));
73
81
  }
74
- });
82
+ }), R = /* @__PURE__ */ k(A, [["__scopeId", "data-v-813a7dbb"]]);
75
83
  export {
76
- D as default
84
+ R as default
77
85
  };