@threlte/flex 0.0.4 → 0.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/Flex/Flex.svelte
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<script>import { forwardEventHandlers } from '@threlte/core';
|
|
2
2
|
import { loadYoga } from 'yoga-layout';
|
|
3
|
-
import InnerFlex from './
|
|
3
|
+
import InnerFlex from './InnerFlex.svelte';
|
|
4
4
|
let yoga;
|
|
5
5
|
const initialize = async () => {
|
|
6
6
|
yoga = await loadYoga();
|
|
@@ -1,56 +1,34 @@
|
|
|
1
|
-
import { SvelteComponent } from
|
|
2
|
-
import type {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
height?: number | undefined;
|
|
16
|
-
width?: number | undefined;
|
|
17
|
-
maxHeight?: unknown;
|
|
18
|
-
maxWidth?: unknown;
|
|
19
|
-
minHeight?: unknown;
|
|
20
|
-
minWidth?: unknown;
|
|
21
|
-
top?: unknown;
|
|
22
|
-
right?: unknown;
|
|
23
|
-
bottom?: unknown;
|
|
24
|
-
left?: unknown;
|
|
25
|
-
padding?: unknown;
|
|
26
|
-
paddingTop?: unknown;
|
|
27
|
-
paddingRight?: unknown;
|
|
28
|
-
paddingBottom?: unknown;
|
|
29
|
-
paddingLeft?: unknown;
|
|
30
|
-
margin?: unknown;
|
|
31
|
-
marginTop?: unknown;
|
|
32
|
-
marginRight?: unknown;
|
|
33
|
-
marginBottom?: unknown;
|
|
34
|
-
marginLeft?: unknown;
|
|
35
|
-
gap?: unknown;
|
|
36
|
-
gapColumn?: unknown;
|
|
37
|
-
gapRow?: unknown;
|
|
38
|
-
aspectRatio?: unknown;
|
|
39
|
-
yoga: Yoga;
|
|
40
|
-
plane?: import("../lib/props").FlexPlane | undefined;
|
|
41
|
-
direction?: string | number | symbol | undefined;
|
|
42
|
-
scaleFactor?: number | undefined;
|
|
43
|
-
class?: string | undefined;
|
|
44
|
-
classParser?: import("../lib/props").ClassParser | undefined;
|
|
45
|
-
};
|
|
46
|
-
slots: InnerFlexSlots;
|
|
47
|
-
events: InnerFlexEvents;
|
|
48
|
-
};
|
|
49
|
-
type InnerFlexProps_ = typeof __propDef.props;
|
|
50
|
-
export { InnerFlexProps_ as InnerFlexProps };
|
|
51
|
-
type InnerFlexEvents_ = typeof __propDef.events;
|
|
52
|
-
export { InnerFlexEvents_ as InnerFlexEvents };
|
|
53
|
-
type InnerFlexSlots_ = typeof __propDef.slots;
|
|
54
|
-
export { InnerFlexSlots_ as InnerFlexSlots };
|
|
55
|
-
export default class InnerFlex extends SvelteComponent<InnerFlexProps, InnerFlexEvents, InnerFlexSlots> {
|
|
1
|
+
import { SvelteComponent } from 'svelte'
|
|
2
|
+
import type { Direction, Yoga } from 'yoga-layout'
|
|
3
|
+
import type { NodeProps } from '../lib/props'
|
|
4
|
+
import type { ClassParser, FlexPlane } from '../lib/props'
|
|
5
|
+
|
|
6
|
+
type InnerFlexProps = NodeProps & {
|
|
7
|
+
yoga: Yoga
|
|
8
|
+
width?: number
|
|
9
|
+
height?: number
|
|
10
|
+
plane?: FlexPlane
|
|
11
|
+
direction?: keyof typeof Direction
|
|
12
|
+
scaleFactor?: number
|
|
13
|
+
class?: string
|
|
14
|
+
classParser?: ClassParser
|
|
56
15
|
}
|
|
16
|
+
|
|
17
|
+
type InnerFlexEvents = {
|
|
18
|
+
reflow: {
|
|
19
|
+
width: number
|
|
20
|
+
height: number
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
type InnerFlexSlots = {
|
|
25
|
+
default: {
|
|
26
|
+
reflow: () => void
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
export default class InnerFlex extends SvelteComponent<
|
|
31
|
+
InnerFlexProps,
|
|
32
|
+
InnerFlexEvents,
|
|
33
|
+
InnerFlexSlots
|
|
34
|
+
> {}
|
package/package.json
CHANGED
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import { SvelteComponent } from 'svelte'
|
|
2
|
-
import type { Direction, Yoga } from 'yoga-layout'
|
|
3
|
-
import type { NodeProps } from '../lib/props'
|
|
4
|
-
import type { ClassParser, FlexPlane } from '../lib/props'
|
|
5
|
-
|
|
6
|
-
type InnerFlexProps = NodeProps & {
|
|
7
|
-
yoga: Yoga
|
|
8
|
-
width?: number
|
|
9
|
-
height?: number
|
|
10
|
-
plane?: FlexPlane
|
|
11
|
-
direction?: keyof typeof Direction
|
|
12
|
-
scaleFactor?: number
|
|
13
|
-
class?: string
|
|
14
|
-
classParser?: ClassParser
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
type InnerFlexEvents = {
|
|
18
|
-
reflow: {
|
|
19
|
-
width: number
|
|
20
|
-
height: number
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
type InnerFlexSlots = {
|
|
25
|
-
default: {
|
|
26
|
-
reflow: () => void
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
export default class InnerFlex extends SvelteComponent<
|
|
31
|
-
InnerFlexProps,
|
|
32
|
-
InnerFlexEvents,
|
|
33
|
-
InnerFlexSlots
|
|
34
|
-
> {}
|