@elmethis/core 0.2.1 → 0.2.2

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.
@@ -4,5 +4,5 @@ export interface ElmFragmentIdentifierProps {
4
4
  */
5
5
  id: string;
6
6
  }
7
- declare const _default: import('vue').DefineComponent<ElmFragmentIdentifierProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<ElmFragmentIdentifierProps> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
7
+ declare const _default: import('vue').DefineComponent<ElmFragmentIdentifierProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<ElmFragmentIdentifierProps> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLSpanElement>;
8
8
  export default _default;
@@ -36,7 +36,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
36
36
  });
37
37
  });
38
38
  return (_ctx, _cache) => {
39
- return openBlock(), createElementBlock("div", {
39
+ return openBlock(), createElementBlock("span", {
40
40
  class: normalizeClass(_ctx.$style.fragment)
41
41
  }, [
42
42
  createVNode(ElmMdiIcon, {
@@ -3,15 +3,15 @@
3
3
  try {
4
4
  if (typeof document != "undefined") {
5
5
  var elementStyle = document.createElement("style");
6
- elementStyle.appendChild(document.createTextNode("._fragment_e7xfw_1{display:flex;justify-content:flex-end;align-items:center}._icon_e7xfw_7{padding:.25rem;border-radius:.25rem;transition:background-color .2s;cursor:pointer}._icon_e7xfw_7:hover{background-color:#0000001a}[data-theme=dark] ._icon_e7xfw_7:hover{background-color:#ffffff1a}"));
6
+ elementStyle.appendChild(document.createTextNode("._fragment_qey7q_1{position:absolute;right:0;bottom:-2.5rem;display:flex;justify-content:flex-end;align-items:center}._icon_qey7q_10{padding:.25rem;border-radius:.25rem;transition:background-color .2s;cursor:pointer}._icon_qey7q_10:hover{background-color:#0000001a}[data-theme=dark] ._icon_qey7q_10:hover{background-color:#ffffff1a}"));
7
7
  document.head.appendChild(elementStyle);
8
8
  }
9
9
  } catch (e) {
10
10
  console.error("vite-plugin-css-injected-by-js", e);
11
11
  }
12
12
  })();
13
- const fragment = "_fragment_e7xfw_1";
14
- const icon = "_icon_e7xfw_7";
13
+ const fragment = "_fragment_qey7q_1";
14
+ const icon = "_icon_qey7q_10";
15
15
  const style0 = {
16
16
  fragment,
17
17
  icon
@@ -1,4 +1,4 @@
1
- import { defineComponent, ref, useSlots, createElementBlock, openBlock, Fragment, createBlock, createCommentVNode, resolveDynamicComponent, normalizeStyle, unref, normalizeClass, withCtx, h } from "vue";
1
+ import { defineComponent, ref, useSlots, createBlock, openBlock, resolveDynamicComponent, normalizeStyle, unref, normalizeClass, withCtx, createElementBlock, createCommentVNode, h } from "vue";
2
2
  import { useIntersectionObserver } from "@vueuse/core";
3
3
  import { kebabCase } from "lodash-es";
4
4
  import ElmFragmentIdentifier from "./ElmFragmentIdentifier.vue.mjs";
@@ -38,37 +38,35 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
38
38
  }
39
39
  };
40
40
  return (_ctx, _cache) => {
41
- return openBlock(), createElementBlock(Fragment, null, [
42
- (openBlock(), createBlock(resolveDynamicComponent(`h${_ctx.level}`), {
43
- ref_key: "target",
44
- ref: target,
45
- class: normalizeClass([
46
- _ctx.$style[`h${_ctx.level}`],
47
- _ctx.$style["heading-common"],
48
- unref(headingStyle).heading
49
- ]),
50
- id: _ctx.id ?? unref(kebabCase)(_ctx.text),
51
- style: normalizeStyle({
52
- "--font-size": _ctx.size ?? `${unref(SIZE_MAP)[_ctx.level]}rem`,
53
- "--scale": targetIsVisible.value ? 1 : 0,
54
- "--opacity": targetIsVisible.value ? 1 : 0
55
- })
56
- }, {
57
- default: withCtx(() => [
58
- (openBlock(), createBlock(resolveDynamicComponent(() => renderSlots()))),
59
- _ctx.level === 2 ? (openBlock(), createElementBlock("span", {
60
- key: 0,
61
- class: normalizeClass(_ctx.$style["h2__underline"]),
62
- "aria-hidden": ""
63
- }, null, 2)) : createCommentVNode("", true)
64
- ]),
65
- _: 1
66
- }, 8, ["class", "id", "style"])),
67
- !_ctx.disableFragmentIdentifier ? (openBlock(), createBlock(ElmFragmentIdentifier, {
68
- key: 0,
69
- id: _ctx.id ?? unref(kebabCase)(_ctx.text)
70
- }, null, 8, ["id"])) : createCommentVNode("", true)
71
- ], 64);
41
+ return openBlock(), createBlock(resolveDynamicComponent(`h${_ctx.level}`), {
42
+ ref_key: "target",
43
+ ref: target,
44
+ class: normalizeClass([
45
+ _ctx.$style[`h${_ctx.level}`],
46
+ _ctx.$style["heading-common"],
47
+ unref(headingStyle).heading
48
+ ]),
49
+ id: _ctx.id ?? unref(kebabCase)(_ctx.text),
50
+ style: normalizeStyle({
51
+ "--font-size": _ctx.size ?? `${unref(SIZE_MAP)[_ctx.level]}rem`,
52
+ "--scale": targetIsVisible.value ? 1 : 0,
53
+ "--opacity": targetIsVisible.value ? 1 : 0
54
+ })
55
+ }, {
56
+ default: withCtx(() => [
57
+ (openBlock(), createBlock(resolveDynamicComponent(() => renderSlots()))),
58
+ _ctx.level === 2 ? (openBlock(), createElementBlock("span", {
59
+ key: 0,
60
+ class: normalizeClass(_ctx.$style["h2__underline"]),
61
+ "aria-hidden": ""
62
+ }, null, 2)) : createCommentVNode("", true),
63
+ !_ctx.disableFragmentIdentifier ? (openBlock(), createBlock(ElmFragmentIdentifier, {
64
+ key: 1,
65
+ id: _ctx.id ?? unref(kebabCase)(_ctx.text)
66
+ }, null, 8, ["id"])) : createCommentVNode("", true)
67
+ ]),
68
+ _: 1
69
+ }, 8, ["class", "id", "style"]);
72
70
  };
73
71
  }
74
72
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elmethis/core",
3
- "version": "0.2.1",
3
+ "version": "0.2.2",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },