@bagelink/vue 0.0.394 → 0.0.398

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 +1 @@
1
- {"version":3,"file":"Card.vue.d.ts","sourceRoot":"","sources":["../../src/components/Card.vue"],"names":[],"mappings":"AAiBA;;;;;;;;;;;;;;;;;;;;AA6IA,wBAAwG;AACxG,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AACjE,KAAK,6BAA6B,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAAG;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CAAE,CAAC;AAC9M,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAAE,QAAO;QAClD,MAAM,EAAE,CAAC,CAAC;KACT,CAAA;CAAE,CAAC"}
1
+ {"version":3,"file":"Card.vue.d.ts","sourceRoot":"","sources":["../../src/components/Card.vue"],"names":[],"mappings":"AAkBA;;;;;;;;;;;;;;;;;;;;AA+IA,wBAAwG;AACxG,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AACjE,KAAK,6BAA6B,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAAG;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CAAE,CAAC;AAC9M,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAAE,QAAO;QAClD,MAAM,EAAE,CAAC,CAAC;KACT,CAAA;CAAE,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"SidebarMenu.vue.d.ts","sourceRoot":"","sources":["../../../src/components/layout/SidebarMenu.vue"],"names":[],"mappings":"AAsBA;AAIA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;;;;;;;;;;;;;;;;;;;AAmO7C,wBAAwG;AACxG,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AACjE,KAAK,6BAA6B,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAAG;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CAAE,CAAC;AAC9M,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAAE,QAAO;QAClD,MAAM,EAAE,CAAC,CAAC;KACT,CAAA;CAAE,CAAC"}
1
+ {"version":3,"file":"SidebarMenu.vue.d.ts","sourceRoot":"","sources":["../../../src/components/layout/SidebarMenu.vue"],"names":[],"mappings":"AAoCA;AAIA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;;;;;;;;;;;;;;;;;;;AA2P7C,wBAAwG;AACxG,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AACjE,KAAK,6BAA6B,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAAG;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CAAE,CAAC;AAC9M,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAAE,QAAO;QAClD,MAAM,EAAE,CAAC,CAAC;KACT,CAAA;CAAE,CAAC"}
package/dist/index.cjs CHANGED
@@ -4569,11 +4569,7 @@ var __publicField = (obj, key, value) => {
4569
4569
  return value;
4570
4570
  };
4571
4571
  const axios = axios$1.create({
4572
- // withCredentials to true to send cookies with requests
4573
- headers: {
4574
- "Allow-Control-Allow-Origin": "*",
4575
- withCredentials: true
4576
- }
4572
+ withCredentials: true
4577
4573
  });
4578
4574
  class DataRequest {
4579
4575
  constructor(table, bagel) {
@@ -4653,11 +4649,10 @@ class BagelAuth {
4653
4649
  }
4654
4650
  async validateUser() {
4655
4651
  try {
4656
- const usr = await this.bagel.get("/users/me");
4652
+ const { data: usr } = await axios.get("/users/me", { withCredentials: true });
4657
4653
  this.user = usr;
4658
4654
  return usr;
4659
4655
  } catch (err) {
4660
- console.log(err);
4661
4656
  return null;
4662
4657
  }
4663
4658
  }
@@ -4680,13 +4675,15 @@ class BagelAuth {
4680
4675
  const formData = new FormData();
4681
4676
  formData.append("username", (user == null ? void 0 : user.email) || "");
4682
4677
  formData.append("password", (user == null ? void 0 : user.password) || "");
4678
+ console.log("Logging in");
4683
4679
  try {
4684
4680
  await axios.post("/auth/cookie/login", formData, {
4685
4681
  headers: {
4686
- "Content-Type": "multipart/form-data",
4687
- withCredentials: true
4682
+ withCredentials: true,
4683
+ "Content-Type": "multipart/form-data"
4688
4684
  }
4689
4685
  });
4686
+ axios.defaults.withCredentials = true;
4690
4687
  return this.validateUser();
4691
4688
  } catch (err) {
4692
4689
  throw responses(((_b = (_a2 = err.response) == null ? void 0 : _a2.data) == null ? void 0 : _b.detail) || "LOGIN_BAD_CREDENTIALS");
@@ -4720,7 +4717,6 @@ class BagelAuth {
4720
4717
  class Bagel {
4721
4718
  constructor({ host, onError }) {
4722
4719
  __publicField(this, "host");
4723
- __publicField(this, "axiosInstance", axios);
4724
4720
  __publicField(this, "onError");
4725
4721
  __publicField(this, "read_table", null);
4726
4722
  __publicField(this, "auth", new BagelAuth(this));
@@ -5794,7 +5790,10 @@ const _sfc_main$v = /* @__PURE__ */ vue.defineComponent({
5794
5790
  }
5795
5791
  });
5796
5792
  const DataPreview = /* @__PURE__ */ _export_sfc(_sfc_main$v, [["__scopeId", "data-v-bb2526f9"]]);
5797
- const _hoisted_1$u = { class: "card_label" };
5793
+ const _hoisted_1$u = {
5794
+ key: 0,
5795
+ class: "card_label"
5796
+ };
5798
5797
  const _sfc_main$u = /* @__PURE__ */ vue.defineComponent({
5799
5798
  __name: "Card",
5800
5799
  props: {
@@ -5818,7 +5817,7 @@ const _sfc_main$u = /* @__PURE__ */ vue.defineComponent({
5818
5817
  "overflow-y": _ctx.overflowY
5819
5818
  }])
5820
5819
  }, [
5821
- vue.createElementVNode("span", _hoisted_1$u, vue.toDisplayString(_ctx.label), 1),
5820
+ _ctx.label ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_1$u, vue.toDisplayString(_ctx.label), 1)) : vue.createCommentVNode("", true),
5822
5821
  vue.renderSlot(_ctx.$slots, "default")
5823
5822
  ], 2);
5824
5823
  };
@@ -6417,9 +6416,9 @@ const _sfc_main$l = /* @__PURE__ */ vue.defineComponent({
6417
6416
  };
6418
6417
  }
6419
6418
  });
6420
- const _withScopeId$1 = (n2) => (vue.pushScopeId("data-v-e8219826"), n2 = n2(), vue.popScopeId(), n2);
6419
+ const _withScopeId$2 = (n2) => (vue.pushScopeId("data-v-e8219826"), n2 = n2(), vue.popScopeId(), n2);
6421
6420
  const _hoisted_1$p = ["title"];
6422
- const _hoisted_2$l = /* @__PURE__ */ _withScopeId$1(() => /* @__PURE__ */ vue.createElementVNode("svg", {
6421
+ const _hoisted_2$l = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ vue.createElementVNode("svg", {
6423
6422
  xmlns: "http://www.w3.org/2000/svg",
6424
6423
  height: "24",
6425
6424
  viewBox: "0 -960 960 960",
@@ -18653,9 +18652,9 @@ const _sfc_main$a = /* @__PURE__ */ vue.defineComponent({
18653
18652
  }
18654
18653
  });
18655
18654
  const $el = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["__scopeId", "data-v-0dbacaa0"]]);
18656
- const _withScopeId = (n2) => (vue.pushScopeId("data-v-b87221d6"), n2 = n2(), vue.popScopeId(), n2);
18655
+ const _withScopeId$1 = (n2) => (vue.pushScopeId("data-v-b87221d6"), n2 = n2(), vue.popScopeId(), n2);
18657
18656
  const _hoisted_1$e = ["title"];
18658
- const _hoisted_2$b = /* @__PURE__ */ _withScopeId(() => /* @__PURE__ */ vue.createElementVNode("span", { class: "slider round" }, null, -1));
18657
+ const _hoisted_2$b = /* @__PURE__ */ _withScopeId$1(() => /* @__PURE__ */ vue.createElementVNode("span", { class: "slider round" }, null, -1));
18659
18658
  const _hoisted_3$8 = [
18660
18659
  _hoisted_2$b
18661
18660
  ];
@@ -45125,7 +45124,7 @@ const _hoisted_1$2$1 = {
45125
45124
  class: "layer-marker"
45126
45125
  };
45127
45126
  const _hoisted_2$2$1 = ["x", "y", "fill"];
45128
- const _hoisted_3$1 = ["x1", "y1", "x2", "y2", "stroke", "stroke-opacity", "stroke-width", "stroke-dasharray"];
45127
+ const _hoisted_3$1$1 = ["x1", "y1", "x2", "y2", "stroke", "stroke-opacity", "stroke-width", "stroke-dasharray"];
45129
45128
  const _hoisted_4$1 = {
45130
45129
  key: 1,
45131
45130
  class: "layer-marker"
@@ -45149,7 +45148,7 @@ function render$2(_ctx, _cache, $props, $setup, $data, $options) {
45149
45148
  "stroke-opacity": _ctx.strokeOpacity,
45150
45149
  "stroke-width": _ctx.strokeWidth,
45151
45150
  "stroke-dasharray": _ctx.strokeDasharray
45152
- }, null, 8, _hoisted_3$1)
45151
+ }, null, 8, _hoisted_3$1$1)
45153
45152
  ])) : (vue.openBlock(), vue.createElementBlock("g", _hoisted_4$1, [
45154
45153
  vue.createElementVNode("text", {
45155
45154
  x: _ctx.y + 10,
@@ -46076,8 +46075,10 @@ const _sfc_main$6 = /* @__PURE__ */ vue.defineComponent({
46076
46075
  }
46077
46076
  });
46078
46077
  const Layout = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["__scopeId", "data-v-977dfbf4"]]);
46078
+ const _withScopeId = (n2) => (vue.pushScopeId("data-v-3c893fb1"), n2 = n2(), vue.popScopeId(), n2);
46079
46079
  const _hoisted_1$5 = { class: "w-100 px-075" };
46080
46080
  const _hoisted_2$2 = { key: 0 };
46081
+ const _hoisted_3$1 = /* @__PURE__ */ _withScopeId(() => /* @__PURE__ */ vue.createElementVNode("div", { style: { "flex-grow": "1" } }, null, -1));
46081
46082
  const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
46082
46083
  __name: "SidebarMenu",
46083
46084
  props: {
@@ -46098,7 +46099,7 @@ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
46098
46099
  return (_ctx, _cache) => {
46099
46100
  const _directive_tooltip = vue.resolveDirective("tooltip");
46100
46101
  return vue.openBlock(), vue.createBlock(vue.unref(_sfc_main$u), {
46101
- class: vue.normalizeClass(["flex column gap-05 pt-1 bgl_sidebar", { "wideNav": vue.unref(isOpen) }])
46102
+ class: vue.normalizeClass(["flex column gap-05 pt-1 bgl_sidebar", { wideNav: vue.unref(isOpen) }])
46102
46103
  }, {
46103
46104
  default: vue.withCtx(() => [
46104
46105
  vue.createElementVNode("div", _hoisted_1$5, [
@@ -46130,12 +46131,17 @@ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
46130
46131
  }, 1032, ["to"])), [
46131
46132
  [
46132
46133
  _directive_tooltip,
46133
- { content: nav2.label, disabled: _ctx.open, class: ["nav-tooltip"] },
46134
+ {
46135
+ content: nav2.label,
46136
+ disabled: _ctx.open,
46137
+ class: ["nav-tooltip"]
46138
+ },
46134
46139
  void 0,
46135
46140
  { right: true }
46136
46141
  ]
46137
46142
  ]);
46138
46143
  }), 128)),
46144
+ _hoisted_3$1,
46139
46145
  vue.renderSlot(_ctx.$slots, "footer", {}, void 0, true)
46140
46146
  ]),
46141
46147
  _: 3
@@ -46143,7 +46149,7 @@ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
46143
46149
  };
46144
46150
  }
46145
46151
  });
46146
- const SidebarMenu = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__scopeId", "data-v-65bec778"]]);
46152
+ const SidebarMenu = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__scopeId", "data-v-3c893fb1"]]);
46147
46153
  const _hoisted_1$4 = { class: "m-0 pb-025 txt14 line-height-1" };
46148
46154
  const _sfc_main$4 = /* @__PURE__ */ vue.defineComponent({
46149
46155
  __name: "BottomMenu",
package/dist/index.mjs CHANGED
@@ -4567,11 +4567,7 @@ var __publicField = (obj, key, value) => {
4567
4567
  return value;
4568
4568
  };
4569
4569
  const axios = axios$1.create({
4570
- // withCredentials to true to send cookies with requests
4571
- headers: {
4572
- "Allow-Control-Allow-Origin": "*",
4573
- withCredentials: true
4574
- }
4570
+ withCredentials: true
4575
4571
  });
4576
4572
  class DataRequest {
4577
4573
  constructor(table, bagel) {
@@ -4651,11 +4647,10 @@ class BagelAuth {
4651
4647
  }
4652
4648
  async validateUser() {
4653
4649
  try {
4654
- const usr = await this.bagel.get("/users/me");
4650
+ const { data: usr } = await axios.get("/users/me", { withCredentials: true });
4655
4651
  this.user = usr;
4656
4652
  return usr;
4657
4653
  } catch (err) {
4658
- console.log(err);
4659
4654
  return null;
4660
4655
  }
4661
4656
  }
@@ -4678,13 +4673,15 @@ class BagelAuth {
4678
4673
  const formData = new FormData();
4679
4674
  formData.append("username", (user == null ? void 0 : user.email) || "");
4680
4675
  formData.append("password", (user == null ? void 0 : user.password) || "");
4676
+ console.log("Logging in");
4681
4677
  try {
4682
4678
  await axios.post("/auth/cookie/login", formData, {
4683
4679
  headers: {
4684
- "Content-Type": "multipart/form-data",
4685
- withCredentials: true
4680
+ withCredentials: true,
4681
+ "Content-Type": "multipart/form-data"
4686
4682
  }
4687
4683
  });
4684
+ axios.defaults.withCredentials = true;
4688
4685
  return this.validateUser();
4689
4686
  } catch (err) {
4690
4687
  throw responses(((_b = (_a2 = err.response) == null ? void 0 : _a2.data) == null ? void 0 : _b.detail) || "LOGIN_BAD_CREDENTIALS");
@@ -4718,7 +4715,6 @@ class BagelAuth {
4718
4715
  class Bagel {
4719
4716
  constructor({ host, onError }) {
4720
4717
  __publicField(this, "host");
4721
- __publicField(this, "axiosInstance", axios);
4722
4718
  __publicField(this, "onError");
4723
4719
  __publicField(this, "read_table", null);
4724
4720
  __publicField(this, "auth", new BagelAuth(this));
@@ -5792,7 +5788,10 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
5792
5788
  }
5793
5789
  });
5794
5790
  const DataPreview = /* @__PURE__ */ _export_sfc(_sfc_main$v, [["__scopeId", "data-v-bb2526f9"]]);
5795
- const _hoisted_1$u = { class: "card_label" };
5791
+ const _hoisted_1$u = {
5792
+ key: 0,
5793
+ class: "card_label"
5794
+ };
5796
5795
  const _sfc_main$u = /* @__PURE__ */ defineComponent({
5797
5796
  __name: "Card",
5798
5797
  props: {
@@ -5816,7 +5815,7 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
5816
5815
  "overflow-y": _ctx.overflowY
5817
5816
  }])
5818
5817
  }, [
5819
- createElementVNode("span", _hoisted_1$u, toDisplayString(_ctx.label), 1),
5818
+ _ctx.label ? (openBlock(), createElementBlock("span", _hoisted_1$u, toDisplayString(_ctx.label), 1)) : createCommentVNode("", true),
5820
5819
  renderSlot(_ctx.$slots, "default")
5821
5820
  ], 2);
5822
5821
  };
@@ -6415,9 +6414,9 @@ const _sfc_main$l = /* @__PURE__ */ defineComponent({
6415
6414
  };
6416
6415
  }
6417
6416
  });
6418
- const _withScopeId$1 = (n2) => (pushScopeId("data-v-e8219826"), n2 = n2(), popScopeId(), n2);
6417
+ const _withScopeId$2 = (n2) => (pushScopeId("data-v-e8219826"), n2 = n2(), popScopeId(), n2);
6419
6418
  const _hoisted_1$p = ["title"];
6420
- const _hoisted_2$l = /* @__PURE__ */ _withScopeId$1(() => /* @__PURE__ */ createElementVNode("svg", {
6419
+ const _hoisted_2$l = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("svg", {
6421
6420
  xmlns: "http://www.w3.org/2000/svg",
6422
6421
  height: "24",
6423
6422
  viewBox: "0 -960 960 960",
@@ -18651,9 +18650,9 @@ const _sfc_main$a = /* @__PURE__ */ defineComponent({
18651
18650
  }
18652
18651
  });
18653
18652
  const $el = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["__scopeId", "data-v-0dbacaa0"]]);
18654
- const _withScopeId = (n2) => (pushScopeId("data-v-b87221d6"), n2 = n2(), popScopeId(), n2);
18653
+ const _withScopeId$1 = (n2) => (pushScopeId("data-v-b87221d6"), n2 = n2(), popScopeId(), n2);
18655
18654
  const _hoisted_1$e = ["title"];
18656
- const _hoisted_2$b = /* @__PURE__ */ _withScopeId(() => /* @__PURE__ */ createElementVNode("span", { class: "slider round" }, null, -1));
18655
+ const _hoisted_2$b = /* @__PURE__ */ _withScopeId$1(() => /* @__PURE__ */ createElementVNode("span", { class: "slider round" }, null, -1));
18657
18656
  const _hoisted_3$8 = [
18658
18657
  _hoisted_2$b
18659
18658
  ];
@@ -45123,7 +45122,7 @@ const _hoisted_1$2$1 = {
45123
45122
  class: "layer-marker"
45124
45123
  };
45125
45124
  const _hoisted_2$2$1 = ["x", "y", "fill"];
45126
- const _hoisted_3$1 = ["x1", "y1", "x2", "y2", "stroke", "stroke-opacity", "stroke-width", "stroke-dasharray"];
45125
+ const _hoisted_3$1$1 = ["x1", "y1", "x2", "y2", "stroke", "stroke-opacity", "stroke-width", "stroke-dasharray"];
45127
45126
  const _hoisted_4$1 = {
45128
45127
  key: 1,
45129
45128
  class: "layer-marker"
@@ -45147,7 +45146,7 @@ function render$2(_ctx, _cache, $props, $setup, $data, $options) {
45147
45146
  "stroke-opacity": _ctx.strokeOpacity,
45148
45147
  "stroke-width": _ctx.strokeWidth,
45149
45148
  "stroke-dasharray": _ctx.strokeDasharray
45150
- }, null, 8, _hoisted_3$1)
45149
+ }, null, 8, _hoisted_3$1$1)
45151
45150
  ])) : (openBlock(), createElementBlock("g", _hoisted_4$1, [
45152
45151
  createElementVNode("text", {
45153
45152
  x: _ctx.y + 10,
@@ -46074,8 +46073,10 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
46074
46073
  }
46075
46074
  });
46076
46075
  const Layout = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["__scopeId", "data-v-977dfbf4"]]);
46076
+ const _withScopeId = (n2) => (pushScopeId("data-v-3c893fb1"), n2 = n2(), popScopeId(), n2);
46077
46077
  const _hoisted_1$5 = { class: "w-100 px-075" };
46078
46078
  const _hoisted_2$2 = { key: 0 };
46079
+ const _hoisted_3$1 = /* @__PURE__ */ _withScopeId(() => /* @__PURE__ */ createElementVNode("div", { style: { "flex-grow": "1" } }, null, -1));
46079
46080
  const _sfc_main$5 = /* @__PURE__ */ defineComponent({
46080
46081
  __name: "SidebarMenu",
46081
46082
  props: {
@@ -46096,7 +46097,7 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
46096
46097
  return (_ctx, _cache) => {
46097
46098
  const _directive_tooltip = resolveDirective("tooltip");
46098
46099
  return openBlock(), createBlock(unref(_sfc_main$u), {
46099
- class: normalizeClass(["flex column gap-05 pt-1 bgl_sidebar", { "wideNav": unref(isOpen) }])
46100
+ class: normalizeClass(["flex column gap-05 pt-1 bgl_sidebar", { wideNav: unref(isOpen) }])
46100
46101
  }, {
46101
46102
  default: withCtx(() => [
46102
46103
  createElementVNode("div", _hoisted_1$5, [
@@ -46128,12 +46129,17 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
46128
46129
  }, 1032, ["to"])), [
46129
46130
  [
46130
46131
  _directive_tooltip,
46131
- { content: nav2.label, disabled: _ctx.open, class: ["nav-tooltip"] },
46132
+ {
46133
+ content: nav2.label,
46134
+ disabled: _ctx.open,
46135
+ class: ["nav-tooltip"]
46136
+ },
46132
46137
  void 0,
46133
46138
  { right: true }
46134
46139
  ]
46135
46140
  ]);
46136
46141
  }), 128)),
46142
+ _hoisted_3$1,
46137
46143
  renderSlot(_ctx.$slots, "footer", {}, void 0, true)
46138
46144
  ]),
46139
46145
  _: 3
@@ -46141,7 +46147,7 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
46141
46147
  };
46142
46148
  }
46143
46149
  });
46144
- const SidebarMenu = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__scopeId", "data-v-65bec778"]]);
46150
+ const SidebarMenu = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__scopeId", "data-v-3c893fb1"]]);
46145
46151
  const _hoisted_1$4 = { class: "m-0 pb-025 txt14 line-height-1" };
46146
46152
  const _sfc_main$4 = /* @__PURE__ */ defineComponent({
46147
46153
  __name: "BottomMenu",
package/dist/style.css CHANGED
@@ -752,15 +752,25 @@ th[data-v-10808aad] {
752
752
  }
753
753
 
754
754
  .card_label {
755
+ font-size: 1rem;
756
+ position: relative;
757
+ top: -0.5rem;
758
+ padding: 0.75rem 0;
759
+ display: block;
760
+ border-bottom: 1px solid var(--border-color);
761
+ margin-bottom: 1rem;
762
+ }
763
+ .border .card_label {
755
764
  font-size: 0.7rem;
756
765
  font-weight: 300;
757
- background: rgb(255, 255, 255);
758
- padding: 0px 12px;
759
- display: block;
766
+ background:var(--bgl-white);
767
+ padding: 0 0.75rem;
760
768
  position: absolute;
761
- border-radius: 100px;
762
- top: -8px;
763
- left: 10px;
769
+ top: -0.5rem;
770
+ inset-inline-start: 1rem;
771
+ border-left: 1px solid var(--border-color);
772
+ border-right: 1px solid var(--border-color);
773
+ border-bottom: unset;
764
774
  }
765
775
  .bgl_card {
766
776
  border-radius: var(--card-border-radius);
@@ -1777,72 +1787,72 @@ img.preview[data-v-0dbacaa0] {
1777
1787
  }
1778
1788
 
1779
1789
  .v-popper--theme-tooltip .v-popper__inner {
1780
- background: rgb(255, 255, 255) !important;
1781
- color: var(--bgl-primary) !important;
1782
- font-size: 15px;
1783
- padding: 0.5rem 1rem;
1784
- box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.1);
1790
+ background: rgb(255, 255, 255) !important;
1791
+ color: var(--bgl-primary) !important;
1792
+ font-size: 15px;
1793
+ padding: 0.5rem 1rem;
1794
+ box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.1);
1785
1795
  }
1786
1796
  .wideNav .nav-button .bgl_btn-flex {
1787
- justify-content: flex-start !important;
1797
+ justify-content: flex-start !important;
1788
1798
  }
1789
1799
  .nav-button.router-link-active {
1790
- background: var(--bgl-white) !important;
1791
- color: var(--bgl-primary);
1800
+ background: var(--bgl-white) !important;
1801
+ color: var(--bgl-primary);
1792
1802
  }
1793
1803
 
1794
- .bgl_sidebar[data-v-65bec778] {
1795
- background-color: var(--bgl-primary);
1796
- color: var(--bgl-white);
1797
- overflow: hidden;
1798
- border-radius: var(--card-border-radius);
1799
- margin: 0.5rem;
1800
- width: calc(100% - 1rem);
1801
- padding: 0.5rem;
1802
- overflow-y: auto;
1804
+ .bgl_sidebar[data-v-3c893fb1] {
1805
+ background-color: var(--bgl-primary);
1806
+ color: var(--bgl-white);
1807
+ overflow: hidden;
1808
+ border-radius: var(--card-border-radius);
1809
+ margin: 0.5rem;
1810
+ width: calc(100% - 1rem);
1811
+ padding: 0.5rem;
1812
+ overflow-y: auto;
1803
1813
  }
1804
- .toggleNav[data-v-65bec778]{
1805
- height: 22px !important;
1806
- width: 22px !important;
1807
- opacity: 0.4;
1808
- transition: var(--bgl-transition);
1814
+ .toggleNav[data-v-3c893fb1] {
1815
+ height: 22px !important;
1816
+ width: 22px !important;
1817
+ opacity: 0.4;
1818
+ transition: var(--bgl-transition);
1809
1819
  }
1810
- .toggleNav[data-v-65bec778]:hover{
1811
- opacity: 1;
1820
+ .toggleNav[data-v-3c893fb1]:hover {
1821
+ opacity: 1;
1812
1822
  }
1813
- .wideNav .toggleNav[data-v-65bec778] {
1814
- transform: rotate(180deg);
1823
+ .wideNav .toggleNav[data-v-3c893fb1] {
1824
+ transform: rotate(180deg);
1815
1825
  }
1816
- .wideNav .nav-button[data-v-65bec778] {
1817
- padding-inline-start: 1rem !important;
1818
- width: 100%;
1826
+ .wideNav .nav-button[data-v-3c893fb1] {
1827
+ padding-inline-start: 1rem !important;
1828
+ width: 100%;
1819
1829
  }
1820
- [dir="rtl"] .toggleNav[data-v-65bec778] {
1821
- transform: rotate(180deg);
1830
+ [dir='rtl'] .toggleNav[data-v-3c893fb1] {
1831
+ transform: rotate(180deg);
1822
1832
  }
1823
- [dir="rtl"] .wideNav .toggleNav[data-v-65bec778] {
1824
- transform: rotate(0deg);
1833
+ [dir='rtl'] .wideNav .toggleNav[data-v-3c893fb1] {
1834
+ transform: rotate(0deg);
1825
1835
  }
1826
- .nav-button.bgl_btn-icon[data-v-65bec778] {
1827
- border-radius: var(--btn-border-radius) !important;
1836
+ .nav-button.bgl_btn-icon[data-v-3c893fb1] {
1837
+ border-radius: var(--btn-border-radius) !important;
1828
1838
  }
1829
- .nav-button p[data-v-65bec778] {
1830
- transition: var(--nav-tran);
1831
- animation: fade-65bec778 2s;
1832
- animation-duration: 900ms;
1839
+ .nav-button p[data-v-3c893fb1] {
1840
+ transition: var(--nav-tran);
1841
+ animation: fade-3c893fb1 2s;
1842
+ animation-duration: 900ms;
1833
1843
  }
1834
- @keyframes fade-65bec778 {
1844
+ @keyframes fade-3c893fb1 {
1835
1845
  0% {
1836
- opacity: 0;
1837
- transform: translateX(-20px);
1846
+ opacity: 0;
1847
+ transform: translateX(-20px);
1838
1848
  }
1839
1849
  30% {
1840
- opacity: 0;
1841
- transform: translateX(-20px);
1850
+ opacity: 0;
1851
+ transform: translateX(-20px);
1842
1852
  }
1843
1853
  100% {
1844
- opacity: 1;
1845
- transform: translateX(0);
1854
+ opacity: 1;
1855
+ transform: translateX(0);
1846
1856
  }
1847
1857
  }
1848
1858
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@bagelink/vue",
3
3
  "type": "module",
4
- "version": "0.0.394",
4
+ "version": "0.0.398",
5
5
  "description": "Bagel core sdk packages",
6
6
  "author": {
7
7
  "name": "Neveh Allon",
@@ -8,8 +8,9 @@
8
8
  [bg || '']: bg,
9
9
  'overflow-x': overflowX,
10
10
  'overflow-y': overflowY,
11
- }">
12
- <span class="card_label">
11
+ }"
12
+ >
13
+ <span v-if="label" class="card_label">
13
14
  {{ label }}
14
15
  </span>
15
16
  <slot />
@@ -41,16 +42,29 @@ defineProps<{
41
42
 
42
43
  <style>
43
44
  .card_label {
45
+ font-size: 1rem;
46
+ position: relative;
47
+ top: -0.5rem;
48
+ padding: 0.75rem 0;
49
+ display: block;
50
+ border-bottom: 1px solid var(--border-color);
51
+ margin-bottom: 1rem;
52
+
53
+ }
54
+ .border .card_label {
44
55
  font-size: 0.7rem;
45
56
  font-weight: 300;
46
- background: rgb(255, 255, 255);
47
- padding: 0px 12px;
48
- display: block;
57
+ background:var(--bgl-white);
58
+ padding: 0 0.75rem;
49
59
  position: absolute;
50
- border-radius: 100px;
51
- top: -8px;
52
- left: 10px;
60
+ top: -0.5rem;
61
+ inset-inline-start: 1rem;
62
+ border-left: 1px solid var(--border-color);
63
+ border-right: 1px solid var(--border-color);
64
+ border-bottom: unset;
65
+
53
66
  }
67
+
54
68
  .bgl_card {
55
69
  border-radius: var(--card-border-radius);
56
70
  background: var(--bgl-white);
@@ -1,15 +1,28 @@
1
1
  <template>
2
- <Card class="flex column gap-05 pt-1 bgl_sidebar" :class="{ 'wideNav': isOpen }">
2
+ <Card
3
+ class="flex column gap-05 pt-1 bgl_sidebar"
4
+ :class="{ wideNav: isOpen }">
3
5
  <div class="w-100 px-075">
4
- <Btn thin color="light" class="toggleNav mb-05" icon="keyboard_arrow_right" @click="toggleMenu" />
6
+ <Btn
7
+ thin
8
+ color="light"
9
+ class="toggleNav mb-05"
10
+ icon="keyboard_arrow_right"
11
+ @click="toggleMenu" />
5
12
  </div>
6
13
  <slot v-if="!isOpen || !slots['brand-open']" name="brand" />
7
14
  <slot v-if="isOpen" name="brand-open" />
8
15
  <slot v-if="!navLinks" />
9
16
  <Btn
10
- v-for="(nav, i) in navLinks" :key="i" :to="nav.to" class="nav-button px-075"
11
- v-tooltip.right="{ content: nav.label, disabled: open, class: ['nav-tooltip'] }"
12
- >
17
+ v-for="(nav, i) in navLinks"
18
+ :key="i"
19
+ :to="nav.to"
20
+ class="nav-button px-075"
21
+ v-tooltip.right="{
22
+ content: nav.label,
23
+ disabled: open,
24
+ class: ['nav-tooltip'],
25
+ }">
13
26
  <template #default>
14
27
  <Icon :icon="nav.icon" :size="1.4" />
15
28
  <p v-if="open">
@@ -17,6 +30,7 @@
17
30
  </p>
18
31
  </template>
19
32
  </Btn>
33
+ <div style="flex-grow: 1" />
20
34
  <slot name="footer" />
21
35
  </Card>
22
36
  </template>
@@ -28,7 +42,11 @@ import type { NavLink } from '@bagelink/vue';
28
42
 
29
43
  const slots = useSlots();
30
44
 
31
- const props = defineProps<{ navLinks?: NavLink[], expandable?: boolean, open: boolean }>();
45
+ const props = defineProps<{
46
+ navLinks?: NavLink[];
47
+ expandable?: boolean;
48
+ open: boolean;
49
+ }>();
32
50
 
33
51
  let isOpen = $ref(props.open);
34
52
 
@@ -41,85 +59,85 @@ function toggleMenu() {
41
59
 
42
60
  <style>
43
61
  .v-popper--theme-tooltip .v-popper__inner {
44
- background: rgb(255, 255, 255) !important;
45
- color: var(--bgl-primary) !important;
46
- font-size: 15px;
47
- padding: 0.5rem 1rem;
48
- box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.1);
62
+ background: rgb(255, 255, 255) !important;
63
+ color: var(--bgl-primary) !important;
64
+ font-size: 15px;
65
+ padding: 0.5rem 1rem;
66
+ box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.1);
49
67
  }
50
68
 
51
69
  .wideNav .nav-button .bgl_btn-flex {
52
- justify-content: flex-start !important;
70
+ justify-content: flex-start !important;
53
71
  }
54
72
 
55
73
  .nav-button.router-link-active {
56
- background: var(--bgl-white) !important;
57
- color: var(--bgl-primary);
74
+ background: var(--bgl-white) !important;
75
+ color: var(--bgl-primary);
58
76
  }
59
77
  </style>
60
78
 
61
79
  <style scoped>
62
80
  .bgl_sidebar {
63
- background-color: var(--bgl-primary);
64
- color: var(--bgl-white);
65
- overflow: hidden;
66
- border-radius: var(--card-border-radius);
67
- margin: 0.5rem;
68
- width: calc(100% - 1rem);
69
- padding: 0.5rem;
70
- overflow-y: auto;
81
+ background-color: var(--bgl-primary);
82
+ color: var(--bgl-white);
83
+ overflow: hidden;
84
+ border-radius: var(--card-border-radius);
85
+ margin: 0.5rem;
86
+ width: calc(100% - 1rem);
87
+ padding: 0.5rem;
88
+ overflow-y: auto;
71
89
  }
72
- .toggleNav{
73
- height: 22px !important;
74
- width: 22px !important;
75
- opacity: 0.4;
76
- transition: var(--bgl-transition);
90
+ .toggleNav {
91
+ height: 22px !important;
92
+ width: 22px !important;
93
+ opacity: 0.4;
94
+ transition: var(--bgl-transition);
77
95
  }
78
- .toggleNav:hover{
79
- opacity: 1;
96
+ .toggleNav:hover {
97
+ opacity: 1;
80
98
  }
81
99
 
82
100
  .wideNav .toggleNav {
83
- transform: rotate(180deg);
101
+ transform: rotate(180deg);
84
102
  }
85
103
 
86
104
  .wideNav .nav-button {
87
- padding-inline-start: 1rem !important;
88
- width: 100%;
105
+ padding-inline-start: 1rem !important;
106
+ width: 100%;
89
107
  }
90
108
 
91
- [dir="rtl"] .toggleNav {
92
- transform: rotate(180deg);
109
+ [dir='rtl'] .toggleNav {
110
+ transform: rotate(180deg);
93
111
  }
94
112
 
95
- [dir="rtl"] .wideNav .toggleNav {
96
- transform: rotate(0deg);
113
+ [dir='rtl'] .wideNav .toggleNav {
114
+ transform: rotate(0deg);
97
115
  }
98
116
 
99
117
  .nav-button.bgl_btn-icon {
100
- border-radius: var(--btn-border-radius) !important;
118
+ border-radius: var(--btn-border-radius) !important;
101
119
  }
102
120
 
103
121
  .nav-button p {
104
- transition: var(--nav-tran);
105
- animation: fade 2s;
106
- animation-duration: 900ms;
122
+ transition: var(--nav-tran);
123
+ animation: fade 2s;
124
+ animation-duration: 900ms;
107
125
  }
108
126
 
109
127
  @keyframes fade {
110
- 0% {
111
- opacity: 0;
112
- transform: translateX(-20px);
113
- }
114
-
115
- 30% {
116
- opacity: 0;
117
- transform: translateX(-20px);
118
- }
119
-
120
- 100% {
121
- opacity: 1;
122
- transform: translateX(0);
123
- }
128
+ 0% {
129
+ opacity: 0;
130
+ transform: translateX(-20px);
131
+ }
132
+
133
+ 30% {
134
+ opacity: 0;
135
+ transform: translateX(-20px);
136
+ }
137
+
138
+ 100% {
139
+ opacity: 1;
140
+ transform: translateX(0);
141
+ }
124
142
  }
125
143
  </style>