@amsom-habitat/ui 1.0.3 → 1.0.5

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.
package/dist/ui.js CHANGED
@@ -13,21 +13,25 @@ const d = (t, s) => {
13
13
  }
14
14
  },
15
15
  emits: ["close"]
16
- }, y = { class: "container bg-white rounded-4 p-3 m-3 position-relative" }, b = { class: "amsom-modal-body" }, k = /* @__PURE__ */ e("div", { class: "mt-2" }, null, -1);
17
- function g(t, s, o, a, l, m) {
18
- const _ = u("font-awesome-icon");
16
+ }, y = { class: "container bg-white rounded-4 p-3 m-3 position-relative" }, b = {
17
+ class: "overflow-y-auto",
18
+ style: { "max-height": "80vh" }
19
+ }, k = /* @__PURE__ */ e("div", { class: "mt-2" }, null, -1);
20
+ function g(t, s, o, a, l, _) {
21
+ const p = u("font-awesome-icon");
19
22
  return n(), i("div", {
20
- class: "amsom-modal-block bg-black bg-opacity-25 position-fixed top-50 start-50 translate-middle min-vw-100 min-vh-100 d-flex justify-content-center align-items-center",
21
- onClick: s[1] || (s[1] = f((p) => o.closeOption ? t.$emit("close") : "", ["self"]))
23
+ class: "amsom-modal-block bg-black bg-opacity-25 position-fixed top-50 start-50 translate-middle min-vw-100 min-vh-100 d-flex justify-content-center align-items-center overflow-y-auto",
24
+ style: { "z-index": "1055" },
25
+ onClick: s[1] || (s[1] = f((m) => o.closeOption ? t.$emit("close") : "", ["self"]))
22
26
  }, [
23
27
  e("div", y, [
24
- o.closeOption ? (n(), h(_, {
28
+ o.closeOption ? (n(), h(p, {
25
29
  key: 0,
26
30
  icon: "fa-solid fa-times",
27
31
  role: "button",
28
32
  class: "position-absolute top-0 end-0 m-3 translate-middle-y",
29
33
  size: "lg",
30
- onClick: s[0] || (s[0] = (p) => t.$emit("close"))
34
+ onClick: s[0] || (s[0] = (m) => t.$emit("close"))
31
35
  })) : r("", !0),
32
36
  e("div", b, [
33
37
  k,
@@ -46,11 +50,11 @@ const A = /* @__PURE__ */ d(v, [["render", g]]), x = {
46
50
  }, w = { class: "card" }, C = { class: "card-body" }, O = {
47
51
  key: 0,
48
52
  class: "card-title"
49
- }, B = /* @__PURE__ */ e("h5", { class: "card-title" }, " Card title ", -1), S = /* @__PURE__ */ e("p", { class: "card-text" }, " Some quick example text to build on the card title and make up the bulk of the card's content. ", -1), M = /* @__PURE__ */ e("a", {
53
+ }, B = /* @__PURE__ */ e("h5", { class: "card-title" }, " Card title ", -1), S = /* @__PURE__ */ e("p", { class: "card-text" }, " Some quick example text to build on the card title and make up the bulk of the card's content. ", -1), z = /* @__PURE__ */ e("a", {
50
54
  href: "#",
51
55
  class: "btn btn-primary"
52
56
  }, "Go somewhere", -1);
53
- function j(t, s, o, a, l, m) {
57
+ function M(t, s, o, a, l, _) {
54
58
  return n(), i("div", w, [
55
59
  e("div", C, [
56
60
  c(t.$slots, "header", {}, () => [
@@ -59,12 +63,12 @@ function j(t, s, o, a, l, m) {
59
63
  c(t.$slots, "default", {}, () => [
60
64
  B,
61
65
  S,
62
- M
66
+ z
63
67
  ])
64
68
  ])
65
69
  ]);
66
70
  }
67
- const F = /* @__PURE__ */ d(x, [["render", j]]), z = {
71
+ const F = /* @__PURE__ */ d(x, [["render", M]]), j = {
68
72
  name: "Overlay",
69
73
  props: {
70
74
  loading: {
@@ -84,7 +88,7 @@ const F = /* @__PURE__ */ d(x, [["render", j]]), z = {
84
88
  ], -1), q = [
85
89
  V
86
90
  ];
87
- function D(t, s, o, a, l, m) {
91
+ function D(t, s, o, a, l, _) {
88
92
  return n(), i("div", null, [
89
93
  e("div", E, [
90
94
  o.loading ? (n(), i("div", N, q)) : r("", !0),
@@ -94,7 +98,7 @@ function D(t, s, o, a, l, m) {
94
98
  ])
95
99
  ]);
96
100
  }
97
- const H = /* @__PURE__ */ d(z, [["render", D]]);
101
+ const H = /* @__PURE__ */ d(j, [["render", D]]);
98
102
  export {
99
103
  F as Card,
100
104
  A as Modal,
package/dist/ui.umd.cjs CHANGED
@@ -1 +1 @@
1
- (function(o,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(o=typeof globalThis<"u"?globalThis:o||self,e(o.UI={},o.Vue))})(this,function(o,e){"use strict";const a=(t,s)=>{const n=t.__vccOpts||t;for(const[l,i]of s)n[l]=i;return n},r={name:"Modal",props:{closeOption:{type:Boolean,default:!1}},emits:["close"]},m={class:"container bg-white rounded-4 p-3 m-3 position-relative"},p={class:"amsom-modal-body"},_=e.createElementVNode("div",{class:"mt-2"},null,-1);function f(t,s,n,l,i,d){const x=e.resolveComponent("font-awesome-icon");return e.openBlock(),e.createElementBlock("div",{class:"amsom-modal-block bg-black bg-opacity-25 position-fixed top-50 start-50 translate-middle min-vw-100 min-vh-100 d-flex justify-content-center align-items-center",onClick:s[1]||(s[1]=e.withModifiers(M=>n.closeOption?t.$emit("close"):"",["self"]))},[e.createElementVNode("div",m,[n.closeOption?(e.openBlock(),e.createBlock(x,{key:0,icon:"fa-solid fa-times",role:"button",class:"position-absolute top-0 end-0 m-3 translate-middle-y",size:"lg",onClick:s[0]||(s[0]=M=>t.$emit("close"))})):e.createCommentVNode("",!0),e.createElementVNode("div",p,[_,e.renderSlot(t.$slots,"default")])])])}const c=a(r,[["render",f]]),h={name:"Card",props:{title:{type:String}}},k={class:"card"},y={class:"card-body"},$={key:0,class:"card-title"},b=e.createElementVNode("h5",{class:"card-title"}," Card title ",-1),u=e.createElementVNode("p",{class:"card-text"}," Some quick example text to build on the card title and make up the bulk of the card's content. ",-1),g=e.createElementVNode("a",{href:"#",class:"btn btn-primary"},"Go somewhere",-1);function E(t,s,n,l,i,d){return e.openBlock(),e.createElementBlock("div",k,[e.createElementVNode("div",y,[e.renderSlot(t.$slots,"header",{},()=>[n.title?(e.openBlock(),e.createElementBlock("h4",$,e.toDisplayString(n.title),1)):e.createCommentVNode("",!0)]),e.renderSlot(t.$slots,"default",{},()=>[b,u,g])])])}const V=a(h,[["render",E]]),B={name:"Overlay",props:{loading:{type:Boolean,default:!1}}},N={class:"position-relative"},C={key:0,class:"position-absolute w-100 h-100 d-flex align-items-center justify-content-center z-index-50 rounded",style:{"background-color":"rgba(193, 193, 193, 0.592)","box-shadow":"inset 0 0 0 10px rgba(193, 193, 193, 0.5)"}},S=[e.createElementVNode("div",{class:"spinner-border text-primary position-sticky sticky-top",role:"status"},[e.createElementVNode("span",{class:"sr-only"},"Chargement...")],-1)];function w(t,s,n,l,i,d){return e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",N,[n.loading?(e.openBlock(),e.createElementBlock("div",C,S)):e.createCommentVNode("",!0),e.createElementVNode("div",null,[e.renderSlot(t.$slots,"default")])])])}const O=a(B,[["render",w]]);o.Card=V,o.Modal=c,o.Overlay=O,o.default=c,Object.defineProperties(o,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
1
+ (function(o,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(o=typeof globalThis<"u"?globalThis:o||self,e(o.UI={},o.Vue))})(this,function(o,e){"use strict";const a=(t,s)=>{const n=t.__vccOpts||t;for(const[l,i]of s)n[l]=i;return n},r={name:"Modal",props:{closeOption:{type:Boolean,default:!1}},emits:["close"]},m={class:"container bg-white rounded-4 p-3 m-3 position-relative"},p={class:"overflow-y-auto",style:{"max-height":"80vh"}},f=e.createElementVNode("div",{class:"mt-2"},null,-1);function _(t,s,n,l,i,d){const O=e.resolveComponent("font-awesome-icon");return e.openBlock(),e.createElementBlock("div",{class:"amsom-modal-block bg-black bg-opacity-25 position-fixed top-50 start-50 translate-middle min-vw-100 min-vh-100 d-flex justify-content-center align-items-center overflow-y-auto",style:{"z-index":"1055"},onClick:s[1]||(s[1]=e.withModifiers(M=>n.closeOption?t.$emit("close"):"",["self"]))},[e.createElementVNode("div",m,[n.closeOption?(e.openBlock(),e.createBlock(O,{key:0,icon:"fa-solid fa-times",role:"button",class:"position-absolute top-0 end-0 m-3 translate-middle-y",size:"lg",onClick:s[0]||(s[0]=M=>t.$emit("close"))})):e.createCommentVNode("",!0),e.createElementVNode("div",p,[f,e.renderSlot(t.$slots,"default")])])])}const c=a(r,[["render",_]]),h={name:"Card",props:{title:{type:String}}},y={class:"card"},k={class:"card-body"},$={key:0,class:"card-title"},u=e.createElementVNode("h5",{class:"card-title"}," Card title ",-1),b=e.createElementVNode("p",{class:"card-text"}," Some quick example text to build on the card title and make up the bulk of the card's content. ",-1),g=e.createElementVNode("a",{href:"#",class:"btn btn-primary"},"Go somewhere",-1);function E(t,s,n,l,i,d){return e.openBlock(),e.createElementBlock("div",y,[e.createElementVNode("div",k,[e.renderSlot(t.$slots,"header",{},()=>[n.title?(e.openBlock(),e.createElementBlock("h4",$,e.toDisplayString(n.title),1)):e.createCommentVNode("",!0)]),e.renderSlot(t.$slots,"default",{},()=>[u,b,g])])])}const V=a(h,[["render",E]]),B={name:"Overlay",props:{loading:{type:Boolean,default:!1}}},N={class:"position-relative"},C={key:0,class:"position-absolute w-100 h-100 d-flex align-items-center justify-content-center z-index-50 rounded",style:{"background-color":"rgba(193, 193, 193, 0.592)","box-shadow":"inset 0 0 0 10px rgba(193, 193, 193, 0.5)"}},w=[e.createElementVNode("div",{class:"spinner-border text-primary position-sticky sticky-top",role:"status"},[e.createElementVNode("span",{class:"sr-only"},"Chargement...")],-1)];function x(t,s,n,l,i,d){return e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",N,[n.loading?(e.openBlock(),e.createElementBlock("div",C,w)):e.createCommentVNode("",!0),e.createElementVNode("div",null,[e.renderSlot(t.$slots,"default")])])])}const S=a(B,[["render",x]]);o.Card=V,o.Modal=c,o.Overlay=S,o.default=c,Object.defineProperties(o,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@amsom-habitat/ui",
3
- "version": "1.0.3",
3
+ "version": "1.0.5",
4
4
  "type": "module",
5
5
  "scripts": {
6
6
  "dev": "vite",
package/dist/style.css DELETED
@@ -1 +0,0 @@
1
- .amsom-modal-body{max-height:80vh;overflow-y:auto}.amsom-modal-block{z-index:1000;overflow-y:auto}