|
| 1 | +import type { JSX } from "@ionic/core/components"; |
1 | 2 | import { defineCustomElement } from "ionicons/components/ion-icon.js"; |
| 3 | +import type { PropType } from "vue"; |
2 | 4 | import { h, defineComponent } from "vue"; |
3 | 5 |
|
4 | 6 | import { getConfig } from "../utils"; |
5 | 7 |
|
6 | | -export const IonIcon = /*@__PURE__*/ defineComponent({ |
7 | | - name: "IonIcon", |
8 | | - props: { |
9 | | - color: String, |
10 | | - flipRtl: Boolean, |
11 | | - icon: String, |
12 | | - ios: String, |
13 | | - lazy: String, |
14 | | - md: String, |
15 | | - mode: String, |
16 | | - name: String, |
17 | | - size: String, |
18 | | - src: String, |
19 | | - }, |
20 | | - setup(props, { slots }) { |
| 8 | +export const IonIcon = /*@__PURE__*/ defineComponent<JSX.IonIcon>( |
| 9 | + (props, { slots }) => { |
21 | 10 | defineCustomElement(); |
22 | 11 | return () => { |
23 | 12 | const { icon, ios, md, mode } = props; |
@@ -47,4 +36,19 @@ export const IonIcon = /*@__PURE__*/ defineComponent({ |
47 | 36 | ); |
48 | 37 | }; |
49 | 38 | }, |
50 | | -}); |
| 39 | + { |
| 40 | + name: "IonIcon", |
| 41 | + props: { |
| 42 | + color: { type: String as PropType<string> }, |
| 43 | + flipRtl: { type: Boolean as PropType<boolean> }, |
| 44 | + icon: { type: String as PropType<string> }, |
| 45 | + ios: { type: String as PropType<string> }, |
| 46 | + lazy: { type: Boolean as PropType<boolean> }, |
| 47 | + md: { type: String as PropType<string> }, |
| 48 | + mode: { type: String as PropType<string> }, |
| 49 | + name: { type: String as PropType<string> }, |
| 50 | + size: { type: String as PropType<string> }, |
| 51 | + src: { type: String as PropType<string> }, |
| 52 | + }, |
| 53 | + } |
| 54 | +); |
0 commit comments