diff --git a/src/components/VAudioElementWrapper.vue b/src/components/VAudioElementWrapper.vue index 35a343b..256f2b9 100644 --- a/src/components/VAudioElementWrapper.vue +++ b/src/components/VAudioElementWrapper.vue @@ -17,7 +17,7 @@ const TIMEOUT_MESSAGE = 'timed out'; const CAN_PLAY_MESSAGE = 'can play'; @Component({ }) -export default class AudioElementWrapper extends Vue { +export default class VAudioElementWrapper extends Vue { @Prop({ default: false }) readonly canPause!: boolean; @Prop({ default: 1000 }) readonly timeOut!: number; @Prop({ default: () => [] }) readonly sources!: string[]; diff --git a/src/components/VCardDock.vue b/src/components/VCardDock.vue new file mode 100644 index 0000000..03f4a4c --- /dev/null +++ b/src/components/VCardDock.vue @@ -0,0 +1,23 @@ + + + diff --git a/src/components/VDockableCard.vue b/src/components/VDockableCard.vue new file mode 100644 index 0000000..530313a --- /dev/null +++ b/src/components/VDockableCard.vue @@ -0,0 +1,55 @@ + + + + + diff --git a/src/components/VSlottedSelect.vue b/src/components/VSlottedSelect.vue new file mode 100644 index 0000000..5d79ce1 --- /dev/null +++ b/src/components/VSlottedSelect.vue @@ -0,0 +1,126 @@ + + + + + diff --git a/src/components/VSlottedSelectItem.vue b/src/components/VSlottedSelectItem.vue new file mode 100644 index 0000000..94c427e --- /dev/null +++ b/src/components/VSlottedSelectItem.vue @@ -0,0 +1,27 @@ + + + + + diff --git a/src/styleguide/Styleguide.vue b/src/styleguide/Styleguide.vue index 3fd2c7f..17bb982 100644 --- a/src/styleguide/Styleguide.vue +++ b/src/styleguide/Styleguide.vue @@ -747,6 +747,129 @@ >
<v-modal-video title='title' :sources="[urls]" size="xl"/>
+
+ +
+

VDockableCard

+
+ +
+
<v-dockable-card></v-dockable-card>
+
VDockableCard with title, body slot and footer slot
+
+ + + + +
+
<v-dockable-card title="My title" ></v-dockable-card>
+
VDockableCard with header slot, body slot and footer slot
+
+ + + + + +
+
<v-dockable-card>…</v-dockable-card>
+
Headless VDockableCard
+
+ + +
+
<v-dockable-card :showHeader="false"></v-dockable-card>
+
+
+
+

VCardDock

+
Single column (slot leftCol)
+
+ + + +
+
<v-card-dock><template v-slot:leftCol>…</template></v-card-dock>
+
Two columns (also with slot rightCol)
+
+ + + + +
+
<v-card-dock><template v-slot:leftCol>…</template><template v-slot:rightCol>…</template></v-card-dock>
+
+
+
+

VSlottedSelect

+
+ + + + +
+
<v-slotted-select label="My awesome label" :selected="..." :items="..."><template v-slot:selected="{ selected }">…</template><template v-slot:item="{ item }"></v-slotted-select>
+
VSlottedSelect with groups (items template uses slotted-select-item component)
+
+ + + + + +
+
<v-slotted-select :selected="..." :groups="..."><template v-slot:selected="{ selected }">…</template><template v-slot:group-header="{ group }">…</template><template v-slot:item="{ item }">…</template></v-slotted-select>
+
VSlottedSelect with groups templates are simple p tags...
+
+ + + + + +
+
<v-slotted-select :selected="..." :groups="..."><template v-slot:selected="{ selected }">…</template><template v-slot:group-header="{ group }">…</template><template v-slot:item="{ item }">…</template></v-slotted-select>
@@ -838,9 +961,10 @@ >VAudio
  • VVideo
  • -
  • - VModalVideo -
  • +
  • VModalVideo
  • +
  • VDockableCard
  • +
  • VCardDock
  • +
  • VSlottedSelect
  • @@ -879,6 +1003,10 @@ import VComparisonGroupSelect from '../components/VComparisonGroupSelect.vue'; import VAudio from '../components/VAudio.vue'; import VVideo from '../components/VVideo.vue'; import VModalVideo from '../components/VModalVideo.vue'; +import VDockableCard from '../components/VDockableCard.vue'; +import VCardDock from '../components/VCardDock.vue'; +import VSlottedSelect, { SlottedSelectGroup, SlottedSelectItem } from '../components/VSlottedSelect.vue'; +import VSlottedSelectItem from '../components/VSlottedSelectItem.vue'; import VSplitDateSelect from '@/components/VSplitDateSelect.vue'; import { Component, Vue } from 'vue-property-decorator'; @@ -913,7 +1041,11 @@ import { Component, Vue } from 'vue-property-decorator'; VSplitDateSelect, VAudio, VVideo, - VModalVideo + VModalVideo, + VDockableCard, + VCardDock, + VSlottedSelect, + VSlottedSelectItem } }) export default class Styleguide extends Vue { @@ -1090,6 +1222,48 @@ export default class Styleguide extends Vue { gItems: EntryGroupItem[] = []; + slottedModel: SlottedSelectItem = { + id: '-', + text: 'Select me', + icon: 'play', + additional: 'nothing serious' + }; + + slottedItems: SlottedSelectItem[] = [ + { + id: '-', + text: 'Select me', + icon: 'play', + additional: 'nothing serious' + }, + { + id: 'a', + icon: 'audio', + text: 'Audio', + additional: 'specimen' + } + ]; + + slottedGroups: SlottedSelectGroup[] = [ + { + id: 'g-a', + name: 'GROUP A', + items: this.slottedItems + }, + { + id: 'g-b', + name: 'GROUP B', + items: [ + { + id: 'c', + icon: 'timer', + text: 'I don\'t have additionals', + additional: '' + } + ] + } + ]; + public loadGroups(payload: any): Promise { return Promise.resolve(this.gItems); }