init component
This commit is contained in:
8
node_modules/buetify/lib/components/layout/list/BList.d.ts
generated
vendored
Executable file
8
node_modules/buetify/lib/components/layout/list/BList.d.ts
generated
vendored
Executable file
@@ -0,0 +1,8 @@
|
||||
import { SetupContext, ComponentOptions, FunctionalComponent } from 'vue';
|
||||
export interface BListProps {
|
||||
tag?: string | ComponentOptions | FunctionalComponent;
|
||||
items: unknown[];
|
||||
}
|
||||
export default function BList(props: BListProps, { slots }: SetupContext): import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
||||
[key: string]: any;
|
||||
}> | undefined;
|
||||
19
node_modules/buetify/lib/components/layout/list/BList.js
generated
vendored
Executable file
19
node_modules/buetify/lib/components/layout/list/BList.js
generated
vendored
Executable file
@@ -0,0 +1,19 @@
|
||||
import { isEmpty } from 'fp-ts/lib/Array';
|
||||
import { h } from 'vue';
|
||||
export default function BList(props, {
|
||||
slots
|
||||
}) {
|
||||
if (isEmpty(props.items)) {
|
||||
return h(props.tag ?? 'div', slots.empty && slots.empty());
|
||||
} else {
|
||||
const length = props.items.length;
|
||||
const slot = slots.default;
|
||||
return slot && h(props.tag ?? 'div', props.items.map((item, index) => slot({
|
||||
item,
|
||||
index,
|
||||
length,
|
||||
isLast: index === length - 1
|
||||
})));
|
||||
}
|
||||
}
|
||||
//# sourceMappingURL=BList.js.map
|
||||
1
node_modules/buetify/lib/components/layout/list/BList.js.map
generated
vendored
Executable file
1
node_modules/buetify/lib/components/layout/list/BList.js.map
generated
vendored
Executable file
@@ -0,0 +1 @@
|
||||
{"version":3,"sources":["../../../../src/components/layout/list/BList.ts"],"names":[],"mappings":"AAAA,SAAS,OAAT,QAAwB,iBAAxB;AACA,SAAS,CAAT,QAAuE,KAAvE;AAOA,eAAc,SAAU,KAAV,CAAgB,KAAhB,EAAmC;AAAE,EAAA;AAAF,CAAnC,EAA0D;AACtE,MAAI,OAAO,CAAC,KAAK,CAAC,KAAP,CAAX,EAA0B;AACxB,WAAO,CAAC,CAAC,KAAK,CAAC,GAAN,IAAa,KAAd,EAAqB,KAAK,CAAC,KAAN,IAAe,KAAK,CAAC,KAAN,EAApC,CAAR;AACD,GAFD,MAEO;AACL,UAAM,MAAM,GAAG,KAAK,CAAC,KAAN,CAAY,MAA3B;AACA,UAAM,IAAI,GAAG,KAAK,CAAC,OAAnB;AACA,WACE,IAAI,IACJ,CAAC,CACC,KAAK,CAAC,GAAN,IAAa,KADd,EAEC,KAAK,CAAC,KAAN,CAAY,GAAZ,CAAgB,CAAC,IAAD,EAAO,KAAP,KACd,IAAI,CAAC;AACH,MAAA,IADG;AAEH,MAAA,KAFG;AAGH,MAAA,MAHG;AAIH,MAAA,MAAM,EAAE,KAAK,KAAK,MAAM,GAAG;AAJxB,KAAD,CADN,CAFD,CAFH;AAcD;AACF","sourcesContent":["import { isEmpty } from 'fp-ts/lib/Array';\nimport { h, SetupContext, ComponentOptions, FunctionalComponent } from 'vue';\n\nexport interface BListProps {\n tag?: string | ComponentOptions | FunctionalComponent;\n items: unknown[];\n}\n\nexport default function BList(props: BListProps, { slots }: SetupContext) {\n if (isEmpty(props.items)) {\n return h(props.tag ?? 'div', slots.empty && slots.empty());\n } else {\n const length = props.items.length;\n const slot = slots.default;\n return (\n slot &&\n h(\n props.tag ?? 'div',\n props.items.map((item, index) =>\n slot({\n item,\n index,\n length,\n isLast: index === length - 1\n })\n )\n )\n );\n }\n}\n"],"sourceRoot":"","file":"BList.js"}
|
||||
3
node_modules/buetify/lib/components/layout/list/index.d.ts
generated
vendored
Executable file
3
node_modules/buetify/lib/components/layout/list/index.d.ts
generated
vendored
Executable file
@@ -0,0 +1,3 @@
|
||||
import BList from './BList';
|
||||
export { BList };
|
||||
export default BList;
|
||||
4
node_modules/buetify/lib/components/layout/list/index.js
generated
vendored
Executable file
4
node_modules/buetify/lib/components/layout/list/index.js
generated
vendored
Executable file
@@ -0,0 +1,4 @@
|
||||
import BList from './BList';
|
||||
export { BList };
|
||||
export default BList;
|
||||
//# sourceMappingURL=index.js.map
|
||||
1
node_modules/buetify/lib/components/layout/list/index.js.map
generated
vendored
Executable file
1
node_modules/buetify/lib/components/layout/list/index.js.map
generated
vendored
Executable file
@@ -0,0 +1 @@
|
||||
{"version":3,"sources":["../../../../src/components/layout/list/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAP,MAAkB,SAAlB;AAEA,SAAS,KAAT;AAEA,eAAe,KAAf","sourcesContent":["import BList from './BList';\n\nexport { BList };\n\nexport default BList;\n"],"sourceRoot":"","file":"index.js"}
|
||||
Reference in New Issue
Block a user