@forsakringskassan/docs-live-example 1.4.1 → 1.4.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.
@@ -1,5 +1,24 @@
1
- import { type ExpandAnimation } from "./expand-animation";
1
+ import { type PropType } from "vue";
2
2
  declare const _default: import("vue").DefineComponent<{
3
+ /**
4
+ * Explicitly render example in given language.
5
+ *
6
+ * Must be one of:
7
+ *
8
+ * - `"vue"` - Interpret `template` as a Vue SFC.
9
+ * - `"html"` - Interpret `template` as vanilla HTML.
10
+ *
11
+ * Default is `"auto"` but you should not explicitly set this value
12
+ * yourself. When set to `"auto"` the contents of `template` prop will
13
+ * be autodetected based on some heurestics (subject to change at any
14
+ * time).
15
+ */
16
+ language: {
17
+ type: PropType<"html" | "auto" | "vue">;
18
+ required: false;
19
+ default: string;
20
+ validator(value: string): boolean;
21
+ };
3
22
  template: {
4
23
  type: StringConstructor;
5
24
  required: true;
@@ -20,21 +39,31 @@ declare const _default: import("vue").DefineComponent<{
20
39
  default: () => {};
21
40
  };
22
41
  }, unknown, {
23
- idPrefix: string;
24
- codeLanguage: string;
25
- codeExpand: ExpandAnimation;
26
- }, {
27
- isVue(): boolean;
28
- codeToggleText(): string;
29
- exampleElement(): HTMLElement;
30
- expandableElement(): HTMLElement;
31
- templateElement(): HTMLElement;
42
+ /** Language declared by parent element via `data-language`, if any */
43
+ parentLanguage: string;
44
+ exampleElement: HTMLElement | undefined;
32
45
  }, {
33
- onToggleCode(): void;
34
- compileCode(): void;
35
- compileVue(): Promise<void>;
36
- compileHTML(): Promise<void>;
37
- }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
46
+ templateLanguage(): "vue" | "html";
47
+ }, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
48
+ /**
49
+ * Explicitly render example in given language.
50
+ *
51
+ * Must be one of:
52
+ *
53
+ * - `"vue"` - Interpret `template` as a Vue SFC.
54
+ * - `"html"` - Interpret `template` as vanilla HTML.
55
+ *
56
+ * Default is `"auto"` but you should not explicitly set this value
57
+ * yourself. When set to `"auto"` the contents of `template` prop will
58
+ * be autodetected based on some heurestics (subject to change at any
59
+ * time).
60
+ */
61
+ language: {
62
+ type: PropType<"html" | "auto" | "vue">;
63
+ required: false;
64
+ default: string;
65
+ validator(value: string): boolean;
66
+ };
38
67
  template: {
39
68
  type: StringConstructor;
40
69
  required: true;
@@ -56,6 +85,7 @@ declare const _default: import("vue").DefineComponent<{
56
85
  };
57
86
  }>>, {
58
87
  components: Record<string, any>;
88
+ language: "html" | "auto" | "vue";
59
89
  livedata: Record<string, any>;
60
90
  livemethods: Record<string, any>;
61
91
  }, {}>;
@@ -0,0 +1,35 @@
1
+ import { type PropType } from "vue";
2
+ declare const _default: import("vue").DefineComponent<{
3
+ element: {
4
+ type: {
5
+ new (): HTMLElement;
6
+ prototype: HTMLElement;
7
+ };
8
+ required: true;
9
+ };
10
+ template: {
11
+ type: StringConstructor;
12
+ required: true;
13
+ };
14
+ templateLanguage: {
15
+ type: PropType<"html" | "vue">;
16
+ required: true;
17
+ };
18
+ }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
19
+ element: {
20
+ type: {
21
+ new (): HTMLElement;
22
+ prototype: HTMLElement;
23
+ };
24
+ required: true;
25
+ };
26
+ template: {
27
+ type: StringConstructor;
28
+ required: true;
29
+ };
30
+ templateLanguage: {
31
+ type: PropType<"html" | "vue">;
32
+ required: true;
33
+ };
34
+ }>>, {}, {}>;
35
+ export default _default;
@@ -0,0 +1,7 @@
1
+ /* sfc-style:/home/runner/work/docs-live-example/docs-live-example/src/LiveExampleSourcecode.vue?type=style&index=0 */
2
+ .collapsed[data-v-7a98eb26] {
3
+ display: none;
4
+ }
5
+ .collapsed[aria-expanded=true][data-v-7a98eb26] {
6
+ display: block;
7
+ }