@thinkpixellab-public/px-vue 3.0.1
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/.eslintrc.js +14 -0
- package/.prettierrc.js +10 -0
- package/LICENSE.md +9 -0
- package/README.md +83 -0
- package/assets/feather/activity.svg +1 -0
- package/assets/feather/airplay.svg +1 -0
- package/assets/feather/alert-circle.svg +1 -0
- package/assets/feather/alert-octagon.svg +1 -0
- package/assets/feather/alert-triangle.svg +1 -0
- package/assets/feather/align-center.svg +1 -0
- package/assets/feather/align-justify.svg +1 -0
- package/assets/feather/align-left.svg +1 -0
- package/assets/feather/align-right.svg +1 -0
- package/assets/feather/anchor.svg +1 -0
- package/assets/feather/aperture.svg +1 -0
- package/assets/feather/archive.svg +1 -0
- package/assets/feather/arrow-down-circle.svg +1 -0
- package/assets/feather/arrow-down-left.svg +1 -0
- package/assets/feather/arrow-down-right.svg +1 -0
- package/assets/feather/arrow-down.svg +1 -0
- package/assets/feather/arrow-left-circle.svg +1 -0
- package/assets/feather/arrow-left.svg +1 -0
- package/assets/feather/arrow-right-circle.svg +1 -0
- package/assets/feather/arrow-right.svg +1 -0
- package/assets/feather/arrow-up-circle.svg +1 -0
- package/assets/feather/arrow-up-left.svg +1 -0
- package/assets/feather/arrow-up-right.svg +1 -0
- package/assets/feather/arrow-up.svg +1 -0
- package/assets/feather/at-sign.svg +1 -0
- package/assets/feather/award.svg +1 -0
- package/assets/feather/bar-chart-2.svg +1 -0
- package/assets/feather/bar-chart.svg +1 -0
- package/assets/feather/battery-charging.svg +1 -0
- package/assets/feather/battery.svg +1 -0
- package/assets/feather/bell-off.svg +1 -0
- package/assets/feather/bell.svg +1 -0
- package/assets/feather/bluetooth.svg +1 -0
- package/assets/feather/bold.svg +1 -0
- package/assets/feather/book-open.svg +1 -0
- package/assets/feather/book.svg +1 -0
- package/assets/feather/bookmark.svg +1 -0
- package/assets/feather/box.svg +1 -0
- package/assets/feather/briefcase.svg +1 -0
- package/assets/feather/calendar.svg +1 -0
- package/assets/feather/camera-off.svg +1 -0
- package/assets/feather/camera.svg +1 -0
- package/assets/feather/cast.svg +1 -0
- package/assets/feather/check-circle.svg +1 -0
- package/assets/feather/check-square.svg +1 -0
- package/assets/feather/check.svg +1 -0
- package/assets/feather/chevron-down.svg +1 -0
- package/assets/feather/chevron-left.svg +1 -0
- package/assets/feather/chevron-right.svg +1 -0
- package/assets/feather/chevron-up.svg +1 -0
- package/assets/feather/chevrons-down.svg +1 -0
- package/assets/feather/chevrons-left.svg +1 -0
- package/assets/feather/chevrons-right.svg +1 -0
- package/assets/feather/chevrons-up.svg +1 -0
- package/assets/feather/chrome.svg +1 -0
- package/assets/feather/circle.svg +1 -0
- package/assets/feather/clipboard.svg +1 -0
- package/assets/feather/clock.svg +1 -0
- package/assets/feather/cloud-drizzle.svg +1 -0
- package/assets/feather/cloud-lightning.svg +1 -0
- package/assets/feather/cloud-off.svg +1 -0
- package/assets/feather/cloud-rain.svg +1 -0
- package/assets/feather/cloud-snow.svg +1 -0
- package/assets/feather/cloud.svg +1 -0
- package/assets/feather/code.svg +1 -0
- package/assets/feather/codepen.svg +1 -0
- package/assets/feather/codesandbox.svg +1 -0
- package/assets/feather/coffee.svg +1 -0
- package/assets/feather/columns.svg +1 -0
- package/assets/feather/command.svg +1 -0
- package/assets/feather/compass.svg +1 -0
- package/assets/feather/copy.svg +1 -0
- package/assets/feather/corner-down-left.svg +1 -0
- package/assets/feather/corner-down-right.svg +1 -0
- package/assets/feather/corner-left-down.svg +1 -0
- package/assets/feather/corner-left-up.svg +1 -0
- package/assets/feather/corner-right-down.svg +1 -0
- package/assets/feather/corner-right-up.svg +1 -0
- package/assets/feather/corner-up-left.svg +1 -0
- package/assets/feather/corner-up-right.svg +1 -0
- package/assets/feather/cpu.svg +1 -0
- package/assets/feather/credit-card.svg +1 -0
- package/assets/feather/crop.svg +1 -0
- package/assets/feather/crosshair.svg +1 -0
- package/assets/feather/database.svg +1 -0
- package/assets/feather/delete.svg +1 -0
- package/assets/feather/disc.svg +1 -0
- package/assets/feather/divide-circle.svg +1 -0
- package/assets/feather/divide-square.svg +1 -0
- package/assets/feather/divide.svg +1 -0
- package/assets/feather/dollar-sign.svg +1 -0
- package/assets/feather/download-cloud.svg +1 -0
- package/assets/feather/download.svg +1 -0
- package/assets/feather/dribbble.svg +1 -0
- package/assets/feather/droplet.svg +1 -0
- package/assets/feather/edit-2.svg +1 -0
- package/assets/feather/edit-3.svg +1 -0
- package/assets/feather/edit.svg +1 -0
- package/assets/feather/external-link.svg +1 -0
- package/assets/feather/eye-off.svg +1 -0
- package/assets/feather/eye.svg +1 -0
- package/assets/feather/facebook.svg +1 -0
- package/assets/feather/fast-forward.svg +1 -0
- package/assets/feather/feather.svg +1 -0
- package/assets/feather/figma.svg +1 -0
- package/assets/feather/file-minus.svg +1 -0
- package/assets/feather/file-plus.svg +1 -0
- package/assets/feather/file-text.svg +1 -0
- package/assets/feather/file.svg +1 -0
- package/assets/feather/film.svg +1 -0
- package/assets/feather/filter.svg +1 -0
- package/assets/feather/flag.svg +1 -0
- package/assets/feather/folder-minus.svg +1 -0
- package/assets/feather/folder-plus.svg +1 -0
- package/assets/feather/folder.svg +1 -0
- package/assets/feather/framer.svg +1 -0
- package/assets/feather/frown.svg +1 -0
- package/assets/feather/gift.svg +1 -0
- package/assets/feather/git-branch.svg +1 -0
- package/assets/feather/git-commit.svg +1 -0
- package/assets/feather/git-merge.svg +1 -0
- package/assets/feather/git-pull-request.svg +1 -0
- package/assets/feather/github.svg +1 -0
- package/assets/feather/gitlab.svg +1 -0
- package/assets/feather/globe.svg +1 -0
- package/assets/feather/grid.svg +1 -0
- package/assets/feather/hard-drive.svg +1 -0
- package/assets/feather/hash.svg +1 -0
- package/assets/feather/headphones.svg +1 -0
- package/assets/feather/heart.svg +1 -0
- package/assets/feather/help-circle.svg +1 -0
- package/assets/feather/hexagon.svg +1 -0
- package/assets/feather/home.svg +1 -0
- package/assets/feather/image.svg +1 -0
- package/assets/feather/inbox.svg +1 -0
- package/assets/feather/info.svg +1 -0
- package/assets/feather/instagram.svg +1 -0
- package/assets/feather/italic.svg +1 -0
- package/assets/feather/key.svg +1 -0
- package/assets/feather/layers.svg +1 -0
- package/assets/feather/layout.svg +1 -0
- package/assets/feather/life-buoy.svg +1 -0
- package/assets/feather/link-2.svg +1 -0
- package/assets/feather/link.svg +1 -0
- package/assets/feather/linkedin.svg +1 -0
- package/assets/feather/list.svg +1 -0
- package/assets/feather/loader.svg +1 -0
- package/assets/feather/lock.svg +1 -0
- package/assets/feather/log-in.svg +1 -0
- package/assets/feather/log-out.svg +1 -0
- package/assets/feather/mail.svg +1 -0
- package/assets/feather/map-pin.svg +1 -0
- package/assets/feather/map.svg +1 -0
- package/assets/feather/maximize-2.svg +1 -0
- package/assets/feather/maximize.svg +1 -0
- package/assets/feather/meh.svg +1 -0
- package/assets/feather/menu.svg +1 -0
- package/assets/feather/message-circle.svg +1 -0
- package/assets/feather/message-square.svg +1 -0
- package/assets/feather/mic-off.svg +1 -0
- package/assets/feather/mic.svg +1 -0
- package/assets/feather/minimize-2.svg +1 -0
- package/assets/feather/minimize.svg +1 -0
- package/assets/feather/minus-circle.svg +1 -0
- package/assets/feather/minus-square.svg +1 -0
- package/assets/feather/minus.svg +1 -0
- package/assets/feather/monitor.svg +1 -0
- package/assets/feather/moon.svg +1 -0
- package/assets/feather/more-horizontal.svg +1 -0
- package/assets/feather/more-vertical.svg +1 -0
- package/assets/feather/mouse-pointer.svg +1 -0
- package/assets/feather/move.svg +1 -0
- package/assets/feather/music.svg +1 -0
- package/assets/feather/navigation-2.svg +1 -0
- package/assets/feather/navigation.svg +1 -0
- package/assets/feather/octagon.svg +1 -0
- package/assets/feather/package.svg +1 -0
- package/assets/feather/paperclip.svg +1 -0
- package/assets/feather/pause-circle.svg +1 -0
- package/assets/feather/pause.svg +1 -0
- package/assets/feather/pen-tool.svg +1 -0
- package/assets/feather/percent.svg +1 -0
- package/assets/feather/phone-call.svg +1 -0
- package/assets/feather/phone-forwarded.svg +1 -0
- package/assets/feather/phone-incoming.svg +1 -0
- package/assets/feather/phone-missed.svg +1 -0
- package/assets/feather/phone-off.svg +1 -0
- package/assets/feather/phone-outgoing.svg +1 -0
- package/assets/feather/phone.svg +1 -0
- package/assets/feather/pie-chart.svg +1 -0
- package/assets/feather/play-circle.svg +1 -0
- package/assets/feather/play.svg +1 -0
- package/assets/feather/plus-circle.svg +1 -0
- package/assets/feather/plus-square.svg +1 -0
- package/assets/feather/plus.svg +1 -0
- package/assets/feather/pocket.svg +1 -0
- package/assets/feather/power.svg +1 -0
- package/assets/feather/printer.svg +1 -0
- package/assets/feather/radio.svg +1 -0
- package/assets/feather/refresh-ccw.svg +1 -0
- package/assets/feather/refresh-cw.svg +1 -0
- package/assets/feather/repeat.svg +1 -0
- package/assets/feather/rewind.svg +1 -0
- package/assets/feather/rotate-ccw.svg +1 -0
- package/assets/feather/rotate-cw.svg +1 -0
- package/assets/feather/rss.svg +1 -0
- package/assets/feather/save.svg +1 -0
- package/assets/feather/scissors.svg +1 -0
- package/assets/feather/search.svg +1 -0
- package/assets/feather/send.svg +1 -0
- package/assets/feather/server.svg +1 -0
- package/assets/feather/settings.svg +1 -0
- package/assets/feather/share-2.svg +1 -0
- package/assets/feather/share.svg +1 -0
- package/assets/feather/shield-off.svg +1 -0
- package/assets/feather/shield.svg +1 -0
- package/assets/feather/shopping-bag.svg +1 -0
- package/assets/feather/shopping-cart.svg +1 -0
- package/assets/feather/shuffle.svg +1 -0
- package/assets/feather/sidebar.svg +1 -0
- package/assets/feather/skip-back.svg +1 -0
- package/assets/feather/skip-forward.svg +1 -0
- package/assets/feather/slack.svg +1 -0
- package/assets/feather/slash.svg +1 -0
- package/assets/feather/sliders.svg +1 -0
- package/assets/feather/smartphone.svg +1 -0
- package/assets/feather/smile.svg +1 -0
- package/assets/feather/speaker.svg +1 -0
- package/assets/feather/square.svg +1 -0
- package/assets/feather/star.svg +1 -0
- package/assets/feather/stop-circle.svg +1 -0
- package/assets/feather/sun.svg +1 -0
- package/assets/feather/sunrise.svg +1 -0
- package/assets/feather/sunset.svg +1 -0
- package/assets/feather/table.svg +1 -0
- package/assets/feather/tablet.svg +1 -0
- package/assets/feather/tag.svg +1 -0
- package/assets/feather/target.svg +1 -0
- package/assets/feather/terminal.svg +1 -0
- package/assets/feather/thermometer.svg +1 -0
- package/assets/feather/thumbs-down.svg +1 -0
- package/assets/feather/thumbs-up.svg +1 -0
- package/assets/feather/toggle-left.svg +1 -0
- package/assets/feather/toggle-right.svg +1 -0
- package/assets/feather/tool.svg +1 -0
- package/assets/feather/trash-2.svg +1 -0
- package/assets/feather/trash.svg +1 -0
- package/assets/feather/trello.svg +1 -0
- package/assets/feather/trending-down.svg +1 -0
- package/assets/feather/trending-up.svg +1 -0
- package/assets/feather/triangle.svg +1 -0
- package/assets/feather/truck.svg +1 -0
- package/assets/feather/tv.svg +1 -0
- package/assets/feather/twitch.svg +1 -0
- package/assets/feather/twitter.svg +1 -0
- package/assets/feather/type.svg +1 -0
- package/assets/feather/umbrella.svg +1 -0
- package/assets/feather/underline.svg +1 -0
- package/assets/feather/unlock.svg +1 -0
- package/assets/feather/upload-cloud.svg +1 -0
- package/assets/feather/upload.svg +1 -0
- package/assets/feather/user-check.svg +1 -0
- package/assets/feather/user-minus.svg +1 -0
- package/assets/feather/user-plus.svg +1 -0
- package/assets/feather/user-x.svg +1 -0
- package/assets/feather/user.svg +1 -0
- package/assets/feather/users.svg +1 -0
- package/assets/feather/video-off.svg +1 -0
- package/assets/feather/video.svg +1 -0
- package/assets/feather/voicemail.svg +1 -0
- package/assets/feather/volume-1.svg +1 -0
- package/assets/feather/volume-2.svg +1 -0
- package/assets/feather/volume-x.svg +1 -0
- package/assets/feather/volume.svg +1 -0
- package/assets/feather/watch.svg +1 -0
- package/assets/feather/wifi-off.svg +1 -0
- package/assets/feather/wifi.svg +1 -0
- package/assets/feather/wind.svg +1 -0
- package/assets/feather/x-circle.svg +1 -0
- package/assets/feather/x-octagon.svg +1 -0
- package/assets/feather/x-square.svg +1 -0
- package/assets/feather/x.svg +1 -0
- package/assets/feather/youtube.svg +1 -0
- package/assets/feather/zap-off.svg +1 -0
- package/assets/feather/zap.svg +1 -0
- package/assets/feather/zoom-in.svg +1 -0
- package/assets/feather/zoom-out.svg +1 -0
- package/assets/icons/calendar.svg +6 -0
- package/assets/icons/check.svg +1 -0
- package/assets/icons/close-sm.svg +1 -0
- package/assets/icons/close.svg +1 -0
- package/assets/icons/copy.svg +1 -0
- package/assets/icons/dropdown.svg +8 -0
- package/assets/icons/invalid.svg +1 -0
- package/assets/icons/menu.svg +1 -0
- package/assets/icons/nav-next.svg +1 -0
- package/assets/icons/nav-prev.svg +1 -0
- package/assets/icons/sort-asc.svg +1 -0
- package/assets/icons/sort-desc.svg +1 -0
- package/assets/test/README.md +1 -0
- package/assets/test/trash.svg +8 -0
- package/babel.config.js +16 -0
- package/components/PxAspect.vue +127 -0
- package/components/PxAutoClamp.vue +75 -0
- package/components/PxBalancedText.vue +118 -0
- package/components/PxBase.vue +15 -0
- package/components/PxBaseDate.vue +27 -0
- package/components/PxBaseItems.vue +72 -0
- package/components/PxBaseItemsSelect.vue +230 -0
- package/components/PxBaseResize.vue +60 -0
- package/components/PxBaseToggle.vue +56 -0
- package/components/PxBaseVariants.vue +62 -0
- package/components/PxBaseVisible.vue +40 -0
- package/components/PxCalendar.vue +385 -0
- package/components/PxCard.vue +47 -0
- package/components/PxCardGrid.vue +386 -0
- package/components/PxClock.vue +510 -0
- package/components/PxCopyText.vue +78 -0
- package/components/PxDatePicker.vue +249 -0
- package/components/PxDropdown.vue +181 -0
- package/components/PxExpander.vue +46 -0
- package/components/PxFeatherIcon.vue +29 -0
- package/components/PxFeatherIconButton.vue +19 -0
- package/components/PxFit.vue +274 -0
- package/components/PxFlex.vue +93 -0
- package/components/PxFloat.vue +32 -0
- package/components/PxIcon.vue +43 -0
- package/components/PxIconButton.vue +115 -0
- package/components/PxIdUniquer.vue +59 -0
- package/components/PxModal.vue +365 -0
- package/components/PxNineGrid.vue +94 -0
- package/components/PxPivot.vue +207 -0
- package/components/PxPopup.vue +230 -0
- package/components/PxPortal.vue +138 -0
- package/components/PxPortalTarget.vue +25 -0
- package/components/PxProgressCircle.vue +73 -0
- package/components/PxRadioButton.vue +83 -0
- package/components/PxSideDrawer.vue +164 -0
- package/components/PxSlideTransition.vue +116 -0
- package/components/PxSlides.vue +217 -0
- package/components/PxStylesPreview.vue +129 -0
- package/components/PxSvg.vue +157 -0
- package/components/PxSwiper.vue +271 -0
- package/components/PxSwiperSlide.vue +42 -0
- package/components/PxSyncHeight.vue +137 -0
- package/components/PxTable.vue +323 -0
- package/components/PxTabs.vue +1 -0
- package/components/PxTextbox.vue +90 -0
- package/components/PxToggle.vue +125 -0
- package/components/PxToggleButton.vue +139 -0
- package/components/PxToggleButtonList.vue +131 -0
- package/components/PxTransitionExpand.vue +100 -0
- package/components/PxValidator.vue +431 -0
- package/components/PxVueTest.vue +761 -0
- package/components/README.md +0 -0
- package/dev/data/fruits.js +59 -0
- package/dev/data/random.js +13 -0
- package/dev/demos/Demo-PxBaseDrag.vue +94 -0
- package/dev/demos/Demo-PxCardGrid.vue +53 -0
- package/dev/demos/Demo-PxPivot.vue +58 -0
- package/dev/demos/Demo-PxSideDrawer.vue +72 -0
- package/dev/demos/Demo-PxSlideTransition.vue +86 -0
- package/dev/demos/Demo-PxSlides.vue +142 -0
- package/dev/demos/Demo-PxStylesPreview.vue +46 -0
- package/dev/demos/Demo-PxSwiper.vue +44 -0
- package/dev/demos/DemoPicker.vue +79 -0
- package/dev/dev.vue +56 -0
- package/dev/serve.js +17 -0
- package/package.json +45 -0
- package/plugins/common-client.js +13 -0
- package/plugins/common-lib.js +4 -0
- package/plugins/common.js +39 -0
- package/plugins/filters/aspect.js +14 -0
- package/plugins/filters/date.js +26 -0
- package/plugins/filters/kebab.js +9 -0
- package/plugins/filters/phone.js +7 -0
- package/plugins/filters/slug.js +26 -0
- package/plugins/filters/spacenator.js +11 -0
- package/plugins/filters/stringToItems.js +28 -0
- package/plugins/filters/striphtml.js +10 -0
- package/plugins/mixins/eventBus.js +23 -0
- package/px-styles.config.scss +12 -0
- package/styles/helpers.scss +14 -0
- package/styles/px.scss +6 -0
- package/utils/balanceText.js +123 -0
- package/utils/bem.js +99 -0
- package/utils/cardGrid.js +383 -0
- package/utils/cssStr.js +45 -0
- package/utils/drag.js +363 -0
- package/utils/fit.js +73 -0
- package/utils/tween.js +129 -0
- package/utils/utils.js +167 -0
- package/utils/variants.js +33 -0
- package/vue.config.js +12 -0
|
File without changes
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
export default [
|
|
2
|
+
{
|
|
3
|
+
id: 'apple',
|
|
4
|
+
name: 'Apple',
|
|
5
|
+
color: 'red',
|
|
6
|
+
deliciousNess: 7,
|
|
7
|
+
description:
|
|
8
|
+
'Praesent commodo cursus magna, vel scelerisque nisl consectetur et. Etiam porta sem malesuada magna mollis euismod. Nulla vitae elit libero, a pharetra augue.',
|
|
9
|
+
lastPurchase: new Date('2022-03-01T00:00:00.000Z'),
|
|
10
|
+
image: 'https://source.unsplash.com/MardkT836BU/1600x900',
|
|
11
|
+
},
|
|
12
|
+
{
|
|
13
|
+
id: 'orange',
|
|
14
|
+
name: 'Orange',
|
|
15
|
+
color: 'orange',
|
|
16
|
+
deliciousNess: 8,
|
|
17
|
+
description:
|
|
18
|
+
'Fusce dapibus, tellus ac cursus commodo, tortor mauris condimentum nibh, ut fermentum massa justo sit amet risus. Etiam porta sem malesuada magna mollis euismod.',
|
|
19
|
+
lastPurchase: new Date('2022-02-01T00:00:00.000Z'),
|
|
20
|
+
image: 'https://source.unsplash.com/U1iYwZ8Dx7k/1600x900',
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
id: 'lime',
|
|
24
|
+
name: 'Lime',
|
|
25
|
+
color: 'yellowgreen',
|
|
26
|
+
deliciousNess: 3,
|
|
27
|
+
description: 'Donec sed odio dui. Nullam id dolor id nibh ultricies vehicula ut id elit.',
|
|
28
|
+
lastPurchase: new Date('2022-01-01T00:00:00.000Z'),
|
|
29
|
+
image: 'https://source.unsplash.com/fjc3Ynol3Bs/1600x900',
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
id: 'banana',
|
|
33
|
+
name: 'Banana',
|
|
34
|
+
color: 'gold',
|
|
35
|
+
deliciousNess: 7,
|
|
36
|
+
description: 'Donec id elit non mi porta gravida at eget metus.',
|
|
37
|
+
lastPurchase: new Date('2021-12-01T00:00:00.000Z'),
|
|
38
|
+
image: 'https://source.unsplash.com/sf_1ZDA1YFw/1600x900',
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
id: 'grape',
|
|
42
|
+
name: 'Grape',
|
|
43
|
+
color: 'purple',
|
|
44
|
+
deliciousNess: 5,
|
|
45
|
+
description:
|
|
46
|
+
'Etiam porta sem malesuada magna mollis euismod. Morbi leo risus, porta ac consectetur ac, vestibulum at eros.',
|
|
47
|
+
lastPurchase: new Date('2021-11-01T00:00:00.000Z'),
|
|
48
|
+
image: 'https://source.unsplash.com/ASKgnwyif3E/1600x900',
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
id: 'strawberry',
|
|
52
|
+
name: 'Strawberry',
|
|
53
|
+
color: 'pink',
|
|
54
|
+
deliciousNess: 9,
|
|
55
|
+
description: 'Donec ullamcorper nulla non metus auctor fringilla.',
|
|
56
|
+
lastPurchase: new Date('2021-10-01T00:00:00.000Z'),
|
|
57
|
+
image: 'https://source.unsplash.com/xnRg3xDcNnE/1600x900',
|
|
58
|
+
},
|
|
59
|
+
];
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import fruits from './fruits.js';
|
|
2
|
+
|
|
3
|
+
export default {
|
|
4
|
+
randomFruits(count) {
|
|
5
|
+
let f = [];
|
|
6
|
+
for (let i = 0; i < count; i++) {
|
|
7
|
+
let randomFruit = fruits[Math.floor(Math.random() * fruits.length)];
|
|
8
|
+
|
|
9
|
+
f.push({ ...randomFruit, id: randomFruit.id + '-' + i });
|
|
10
|
+
}
|
|
11
|
+
return f;
|
|
12
|
+
},
|
|
13
|
+
};
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
Describe this component...
|
|
3
|
+
-->
|
|
4
|
+
<template>
|
|
5
|
+
<div :class="bem()">
|
|
6
|
+
<div :class="bem('status')"></div>
|
|
7
|
+
<div
|
|
8
|
+
:class="bem('ball')"
|
|
9
|
+
:style="{ transform: `translate(${cssPx(dx)},${cssPx(dy)})` }"
|
|
10
|
+
></div>
|
|
11
|
+
<div :class="bem('status')">
|
|
12
|
+
<div>dx:{{ dx }}</div>
|
|
13
|
+
<div>dy:{{ dy }}</div>
|
|
14
|
+
<div>isDragging:{{ isDragging }}</div>
|
|
15
|
+
<div>isMoving:{{ isMoving }}</div>
|
|
16
|
+
</div>
|
|
17
|
+
</div>
|
|
18
|
+
</template>
|
|
19
|
+
|
|
20
|
+
<script>
|
|
21
|
+
import drag from '../../utils/drag.js';
|
|
22
|
+
|
|
23
|
+
export default {
|
|
24
|
+
name: 'demo-px-drag-base',
|
|
25
|
+
props: {},
|
|
26
|
+
data() {
|
|
27
|
+
return { dx: 0, dy: 0, isMoving: false, isDragging: false };
|
|
28
|
+
},
|
|
29
|
+
// computed: {},
|
|
30
|
+
// watch: {},
|
|
31
|
+
mounted() {
|
|
32
|
+
this.drag = new drag(this.$el, {
|
|
33
|
+
lock: 'x',
|
|
34
|
+
onStart: () => {
|
|
35
|
+
this.isDragging = true;
|
|
36
|
+
},
|
|
37
|
+
onDrag: ev => {
|
|
38
|
+
this.isMoving = true;
|
|
39
|
+
if (ev.delta) {
|
|
40
|
+
this.dx += ev.delta.x;
|
|
41
|
+
this.dy += ev.delta.y;
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
onEnd: ev => {
|
|
45
|
+
// this.dx = 0;
|
|
46
|
+
// this.dy = 0;
|
|
47
|
+
this.isDragging = false;
|
|
48
|
+
console.log(ev.delta);
|
|
49
|
+
},
|
|
50
|
+
onMoveEnd: () => {
|
|
51
|
+
this.isMoving = false;
|
|
52
|
+
},
|
|
53
|
+
});
|
|
54
|
+
},
|
|
55
|
+
// methods: {},
|
|
56
|
+
};
|
|
57
|
+
</script>
|
|
58
|
+
|
|
59
|
+
<style lang="scss">
|
|
60
|
+
@use '../../styles/px.scss' as *;
|
|
61
|
+
|
|
62
|
+
.demo-px-drag-base {
|
|
63
|
+
width: 100vw;
|
|
64
|
+
height: 60vh;
|
|
65
|
+
background-color: peachpuff;
|
|
66
|
+
border: 4px solid tomato;
|
|
67
|
+
box-sizing: border-box;
|
|
68
|
+
position: relative;
|
|
69
|
+
&__ball {
|
|
70
|
+
position: absolute;
|
|
71
|
+
top: 50%;
|
|
72
|
+
left: 50%;
|
|
73
|
+
margin-left: -60px;
|
|
74
|
+
margin-top: -60px;
|
|
75
|
+
width: 120px;
|
|
76
|
+
height: 120px;
|
|
77
|
+
background-color: tomato;
|
|
78
|
+
border-radius: 50%;
|
|
79
|
+
}
|
|
80
|
+
&__status {
|
|
81
|
+
background-color: accent(-6);
|
|
82
|
+
color: accent(8);
|
|
83
|
+
position: fixed;
|
|
84
|
+
top: 20px;
|
|
85
|
+
right: 20px;
|
|
86
|
+
width: 16em;
|
|
87
|
+
padding: 1.5em;
|
|
88
|
+
border-radius: 0.5em;
|
|
89
|
+
font-family: get('code-font-family');
|
|
90
|
+
font-size: 10px;
|
|
91
|
+
line-height: 1.5;
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
</style>
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
Describe this component...
|
|
3
|
+
-->
|
|
4
|
+
<template>
|
|
5
|
+
<div :class="bem()">
|
|
6
|
+
<px-card-grid
|
|
7
|
+
:items="fruits"
|
|
8
|
+
:debug="true"
|
|
9
|
+
:gap="60"
|
|
10
|
+
:allow-orphans="true"
|
|
11
|
+
:maxColumns="4"
|
|
12
|
+
:templates="{
|
|
13
|
+
4: ['== -- -----', '-- == -- --', '----- -- ==', '-- -- == --'],
|
|
14
|
+
3: ['== -- --', '-- -- ==', '-- == --'],
|
|
15
|
+
2: ['-- --', '-----', '== --'],
|
|
16
|
+
}"
|
|
17
|
+
>
|
|
18
|
+
<template #default="{ item }">{{ item.name }}</template>
|
|
19
|
+
</px-card-grid>
|
|
20
|
+
</div>
|
|
21
|
+
</template>
|
|
22
|
+
|
|
23
|
+
<script>
|
|
24
|
+
import PxCardGrid from '../../components/PxCardGrid.vue';
|
|
25
|
+
// import { mapState } from 'vuex';
|
|
26
|
+
// import Component from '~/components/Component.vue';
|
|
27
|
+
// import Mixin from '~/components/Mixin.vue';
|
|
28
|
+
|
|
29
|
+
import random from '../data/random.js';
|
|
30
|
+
|
|
31
|
+
export default {
|
|
32
|
+
components: { PxCardGrid },
|
|
33
|
+
name: 'demo-px-card-grid',
|
|
34
|
+
// components: { Component },
|
|
35
|
+
// mixins: [ Mixin ],
|
|
36
|
+
// props: { a: { type: Boolean, default: false } },
|
|
37
|
+
data() {
|
|
38
|
+
return { fruits: [] };
|
|
39
|
+
},
|
|
40
|
+
// computed: {},
|
|
41
|
+
// watch: {},
|
|
42
|
+
mounted() {
|
|
43
|
+
this.fruits = random.randomFruits(20);
|
|
44
|
+
},
|
|
45
|
+
// methods: {},
|
|
46
|
+
};
|
|
47
|
+
</script>
|
|
48
|
+
|
|
49
|
+
<style lang="scss">
|
|
50
|
+
.demo-px-card-grid {
|
|
51
|
+
// add styles here
|
|
52
|
+
}
|
|
53
|
+
</style>
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
Describe this component...
|
|
3
|
+
-->
|
|
4
|
+
<template>
|
|
5
|
+
<div :class="bem()">
|
|
6
|
+
<px-pivot :items="tabs" v-model="selectedTab" />
|
|
7
|
+
<px-slides :items="tabs" v-model="selectedTab" :drag-enabled="false">
|
|
8
|
+
<template #slide="{ item }">
|
|
9
|
+
<div :class="bem('slide')">
|
|
10
|
+
<h1>{{ item.label }}</h1>
|
|
11
|
+
</div>
|
|
12
|
+
</template>
|
|
13
|
+
</px-slides>
|
|
14
|
+
</div>
|
|
15
|
+
</template>
|
|
16
|
+
|
|
17
|
+
<script>
|
|
18
|
+
import PxPivot from '../../components/PxPivot.vue';
|
|
19
|
+
import PxSlides from '../../components/PxSlides.vue';
|
|
20
|
+
import stringToItems from '../../plugins/filters/stringToItems.js';
|
|
21
|
+
|
|
22
|
+
// import { mapState } from 'vuex';
|
|
23
|
+
// import Component from '~/components/Component.vue';
|
|
24
|
+
// import Mixin from '~/components/Mixin.vue';
|
|
25
|
+
export default {
|
|
26
|
+
name: 'demo-px-pivot',
|
|
27
|
+
components: { PxPivot, PxSlides },
|
|
28
|
+
filters: { stringToItems },
|
|
29
|
+
// mixins: [ Mixin ],
|
|
30
|
+
// props: { a: { type: Boolean, default: false } },
|
|
31
|
+
data() {
|
|
32
|
+
const tabs = stringToItems('Apple, Orange, Banana, Super Delicious Pineapple');
|
|
33
|
+
tabs[1].hideSelector = true;
|
|
34
|
+
|
|
35
|
+
return { tabs, selectedTab: null };
|
|
36
|
+
},
|
|
37
|
+
// computed: {},
|
|
38
|
+
// watch: {},
|
|
39
|
+
// mounted() {},
|
|
40
|
+
// methods: {},
|
|
41
|
+
};
|
|
42
|
+
</script>
|
|
43
|
+
|
|
44
|
+
<style lang="scss">
|
|
45
|
+
.demo-px-pivot {
|
|
46
|
+
overflow-x: hidden;
|
|
47
|
+
padding: 20vh 0 150vh;
|
|
48
|
+
max-width: 100vw;
|
|
49
|
+
|
|
50
|
+
&__slide {
|
|
51
|
+
margin: 0 auto;
|
|
52
|
+
background-color: rgba(gold, 0.1);
|
|
53
|
+
width: 80vw;
|
|
54
|
+
max-width: 600px;
|
|
55
|
+
aspect-ratio: 4 / 3;
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
</style>
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
Describe this component...
|
|
3
|
+
-->
|
|
4
|
+
<template>
|
|
5
|
+
<div :class="bem()">
|
|
6
|
+
<px-side-drawer>
|
|
7
|
+
<section>
|
|
8
|
+
<a href="#">Link One</a>
|
|
9
|
+
<a href="#">Link Two</a>
|
|
10
|
+
<a href="#">Link Three</a>
|
|
11
|
+
</section>
|
|
12
|
+
|
|
13
|
+
<section>
|
|
14
|
+
<a href="#">Link Four</a>
|
|
15
|
+
<a href="#">Link Five</a>
|
|
16
|
+
<a href="#">Link Six</a>
|
|
17
|
+
</section>
|
|
18
|
+
|
|
19
|
+
<!-- disabled for now...some weirdness with nested modals -->
|
|
20
|
+
<section v-if="false">
|
|
21
|
+
<px-dropdown
|
|
22
|
+
tag="button"
|
|
23
|
+
trigger="click"
|
|
24
|
+
:items="fruits"
|
|
25
|
+
items-value-property="id"
|
|
26
|
+
items-label-property="name"
|
|
27
|
+
items-key-property="id"
|
|
28
|
+
placeholder="Select a fruit..."
|
|
29
|
+
:use-modal="false"
|
|
30
|
+
></px-dropdown>
|
|
31
|
+
</section>
|
|
32
|
+
|
|
33
|
+
<template #bottom>
|
|
34
|
+
<section>
|
|
35
|
+
<a href="#">Bottom</a>
|
|
36
|
+
<a href="#">Also Bottom</a>
|
|
37
|
+
</section>
|
|
38
|
+
</template>
|
|
39
|
+
</px-side-drawer>
|
|
40
|
+
</div>
|
|
41
|
+
</template>
|
|
42
|
+
|
|
43
|
+
<script>
|
|
44
|
+
import PxSideDrawer from '../../components/PxSideDrawer.vue';
|
|
45
|
+
import PxDropdown from '../../components/PxDropdown.vue';
|
|
46
|
+
import random from '../data/random.js';
|
|
47
|
+
|
|
48
|
+
// import { mapState } from 'vuex';
|
|
49
|
+
// import Component from '~/components/Component.vue';
|
|
50
|
+
// import Mixin from '~/components/Mixin.vue';
|
|
51
|
+
export default {
|
|
52
|
+
components: { PxSideDrawer, PxDropdown },
|
|
53
|
+
name: 'demo-px-slide-drawer',
|
|
54
|
+
// components: { Component },
|
|
55
|
+
// mixins: [ Mixin ],
|
|
56
|
+
// props: { a: { type: Boolean, default: false } },
|
|
57
|
+
data() {
|
|
58
|
+
return { fruits: random.randomFruits(5) };
|
|
59
|
+
},
|
|
60
|
+
// computed: {},
|
|
61
|
+
// watch: {},
|
|
62
|
+
// mounted() {},
|
|
63
|
+
// methods: {},
|
|
64
|
+
};
|
|
65
|
+
</script>
|
|
66
|
+
|
|
67
|
+
<style lang="scss">
|
|
68
|
+
@use '../../styles/px.scss' as *;
|
|
69
|
+
.demo-px-slide-drawer {
|
|
70
|
+
// add styles here
|
|
71
|
+
}
|
|
72
|
+
</style>
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
Describe this component...
|
|
3
|
+
-->
|
|
4
|
+
<template>
|
|
5
|
+
<div :class="bem()">
|
|
6
|
+
<div :class="bem('outer')" @click="evenOdd++">
|
|
7
|
+
<px-slide-transition>
|
|
8
|
+
<div v-if="evenOdd % 2" :class="bem('inner', { even: true })" />
|
|
9
|
+
</px-slide-transition>
|
|
10
|
+
<px-slide-transition>
|
|
11
|
+
<div v-if="!(evenOdd % 2)" :class="bem('inner', { odd: true })">
|
|
12
|
+
<div :class="bem('inner-inner')" data-slide>SO INNER</div>
|
|
13
|
+
</div>
|
|
14
|
+
</px-slide-transition>
|
|
15
|
+
</div>
|
|
16
|
+
</div>
|
|
17
|
+
</template>
|
|
18
|
+
|
|
19
|
+
<script>
|
|
20
|
+
// import { mapState } from 'vuex';
|
|
21
|
+
// import Component from '~/components/Component.vue';
|
|
22
|
+
import PxSlideTransition from '../../components/PxSlideTransition.vue';
|
|
23
|
+
|
|
24
|
+
export default {
|
|
25
|
+
name: 'demo-px-slide-transition',
|
|
26
|
+
components: { PxSlideTransition },
|
|
27
|
+
// mixins: [ Mixin ],
|
|
28
|
+
// props: { a: { type: Boolean, default: false } },
|
|
29
|
+
data() {
|
|
30
|
+
return { evenOdd: 0 };
|
|
31
|
+
},
|
|
32
|
+
// computed: {},
|
|
33
|
+
// watch: {},
|
|
34
|
+
// mounted() {},
|
|
35
|
+
// methods: {},
|
|
36
|
+
};
|
|
37
|
+
</script>
|
|
38
|
+
|
|
39
|
+
<style lang="scss">
|
|
40
|
+
@use '../../styles/px.scss' as *;
|
|
41
|
+
|
|
42
|
+
.demo-px-slide-transition {
|
|
43
|
+
&__outer {
|
|
44
|
+
width: 300px;
|
|
45
|
+
height: 300px;
|
|
46
|
+
background-color: hotpink;
|
|
47
|
+
border-radius: 50%;
|
|
48
|
+
position: relative;
|
|
49
|
+
margin: 20px auto;
|
|
50
|
+
padding: 30px;
|
|
51
|
+
box-sizing: border-box;
|
|
52
|
+
display: grid;
|
|
53
|
+
grid-template-columns: 100%;
|
|
54
|
+
grid-template-rows: 100%;
|
|
55
|
+
grid-area: content;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
&__inner {
|
|
59
|
+
width: 100%;
|
|
60
|
+
height: 100%;
|
|
61
|
+
border-radius: 50%;
|
|
62
|
+
background-color: gold;
|
|
63
|
+
display: flex;
|
|
64
|
+
align-items: center;
|
|
65
|
+
justify-content: center;
|
|
66
|
+
|
|
67
|
+
grid-area: 1/1/1/1;
|
|
68
|
+
&--even {
|
|
69
|
+
background-color: purple;
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
&__inner-inner {
|
|
74
|
+
width: 80%;
|
|
75
|
+
height: 80%;
|
|
76
|
+
background-color: orange;
|
|
77
|
+
display: flex;
|
|
78
|
+
align-items: center;
|
|
79
|
+
justify-content: center;
|
|
80
|
+
font-family: sans-serif;
|
|
81
|
+
font-weight: bold;
|
|
82
|
+
color: white;
|
|
83
|
+
border-radius: 50%;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
</style>
|
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
Describe this component...
|
|
3
|
+
-->
|
|
4
|
+
<template>
|
|
5
|
+
<px-flex :class="bem()" vertical style="height: 100%" gap="1">
|
|
6
|
+
<px-flex justify="center" gap="1">
|
|
7
|
+
<button @click="clickPrev">Previous</button>
|
|
8
|
+
<button @click="clickNext">Next</button>
|
|
9
|
+
<px-toggle v-model="nested">Nested</px-toggle>
|
|
10
|
+
</px-flex>
|
|
11
|
+
<px-slides :style="{ flex: 1 }" ref="slides" :items="fruits" items-key-property="id">
|
|
12
|
+
<template #slide="{ item, index }">
|
|
13
|
+
<!-- NESTED -->
|
|
14
|
+
<div v-if="nested && index == 0" :class="bem('nested')">
|
|
15
|
+
<img
|
|
16
|
+
data-drag
|
|
17
|
+
:src="item.image"
|
|
18
|
+
:style="{
|
|
19
|
+
aspectRatio: 1,
|
|
20
|
+
width: '50vw',
|
|
21
|
+
objectFit: 'cover',
|
|
22
|
+
borderRadius: '50%',
|
|
23
|
+
}"
|
|
24
|
+
/>
|
|
25
|
+
|
|
26
|
+
<px-slides :items="fruits" items-key-property="id">
|
|
27
|
+
<template #slide="{ item, index }">
|
|
28
|
+
<div :class="bem('item')">
|
|
29
|
+
<div>
|
|
30
|
+
<h1>NESTED {{ item.name }} {{ index }}</h1>
|
|
31
|
+
</div>
|
|
32
|
+
|
|
33
|
+
<img
|
|
34
|
+
data-drag
|
|
35
|
+
:src="item.image"
|
|
36
|
+
:style="{
|
|
37
|
+
aspectRatio: 1,
|
|
38
|
+
width: '50vw',
|
|
39
|
+
objectFit: 'cover',
|
|
40
|
+
borderRadius: '50%',
|
|
41
|
+
}"
|
|
42
|
+
/>
|
|
43
|
+
</div>
|
|
44
|
+
</template>
|
|
45
|
+
</px-slides>
|
|
46
|
+
</div>
|
|
47
|
+
|
|
48
|
+
<!-- NORMAL -->
|
|
49
|
+
<div v-else :class="bem('item')">
|
|
50
|
+
<div>
|
|
51
|
+
<h1>{{ item.name }} {{ index }}</h1>
|
|
52
|
+
</div>
|
|
53
|
+
|
|
54
|
+
<img
|
|
55
|
+
data-drag
|
|
56
|
+
:src="item.image"
|
|
57
|
+
:style="{
|
|
58
|
+
aspectRatio: 1,
|
|
59
|
+
width: '50vw',
|
|
60
|
+
objectFit: 'cover',
|
|
61
|
+
borderRadius: '50%',
|
|
62
|
+
}"
|
|
63
|
+
/>
|
|
64
|
+
</div>
|
|
65
|
+
</template>
|
|
66
|
+
<!-- <template #item="{ item, index, dragX }">
|
|
67
|
+
<div :class="bem('item')" :style="{ transform: `translate(${dragX}px, 0)` }">
|
|
68
|
+
<px-card :class="bem('card')">
|
|
69
|
+
<div :class="bem('no-swiping')">(no swiping)</div>
|
|
70
|
+
<p>{{ item.name }} ({{ index }})</p>
|
|
71
|
+
<div
|
|
72
|
+
:class="bem('graphic')"
|
|
73
|
+
:style="{
|
|
74
|
+
backgroundColor: item.color,
|
|
75
|
+
}"
|
|
76
|
+
></div>
|
|
77
|
+
</px-card>
|
|
78
|
+
</div>
|
|
79
|
+
</template> -->
|
|
80
|
+
</px-slides>
|
|
81
|
+
</px-flex>
|
|
82
|
+
</template>
|
|
83
|
+
|
|
84
|
+
<script>
|
|
85
|
+
import PxFlex from '../../components/PxFlex.vue';
|
|
86
|
+
import PxSlides from '../../components/PxSlides.vue';
|
|
87
|
+
import PxToggle from '../../components/PxToggle.vue';
|
|
88
|
+
|
|
89
|
+
import random from '../data/random.js';
|
|
90
|
+
|
|
91
|
+
export default {
|
|
92
|
+
name: 'demo-px-slides',
|
|
93
|
+
components: { PxSlides, PxFlex, PxToggle },
|
|
94
|
+
// mixins: [ Mixin ],
|
|
95
|
+
// props: { a: { type: Boolean, default: false } },
|
|
96
|
+
data() {
|
|
97
|
+
return { fruits: [], nested: false };
|
|
98
|
+
},
|
|
99
|
+
// computed: {},
|
|
100
|
+
// watch: {},
|
|
101
|
+
mounted() {
|
|
102
|
+
this.fruits = random.randomFruits(3);
|
|
103
|
+
},
|
|
104
|
+
methods: {
|
|
105
|
+
clickPrev() {
|
|
106
|
+
this.$refs.slides.previous();
|
|
107
|
+
},
|
|
108
|
+
clickNext() {
|
|
109
|
+
this.$refs.slides.next();
|
|
110
|
+
},
|
|
111
|
+
},
|
|
112
|
+
};
|
|
113
|
+
</script>
|
|
114
|
+
|
|
115
|
+
<style lang="scss">
|
|
116
|
+
@use '../../styles/px.scss' as *;
|
|
117
|
+
|
|
118
|
+
.demo-px-slides {
|
|
119
|
+
padding: 10px;
|
|
120
|
+
gap: 10px;
|
|
121
|
+
|
|
122
|
+
width: 100vw;
|
|
123
|
+
box-sizing: border-box;
|
|
124
|
+
overflow: hidden;
|
|
125
|
+
height: 100%;
|
|
126
|
+
display: grid;
|
|
127
|
+
grid-template-columns: 100%;
|
|
128
|
+
grid-template-rows: 100%;
|
|
129
|
+
// min-height: 300vh;
|
|
130
|
+
border: 5px solid hotpink;
|
|
131
|
+
|
|
132
|
+
&__nested {
|
|
133
|
+
background-color: gold;
|
|
134
|
+
font-size: 10px;
|
|
135
|
+
opacity: 0.5;
|
|
136
|
+
display: flex;
|
|
137
|
+
> * {
|
|
138
|
+
flex: 1;
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
</style>
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
Describe this component...
|
|
3
|
+
-->
|
|
4
|
+
<template>
|
|
5
|
+
<div :class="bem()">
|
|
6
|
+
<px-styles-preview />
|
|
7
|
+
</div>
|
|
8
|
+
</template>
|
|
9
|
+
|
|
10
|
+
<script>
|
|
11
|
+
import PxStylesPreview from '../../components/PxStylesPreview.vue';
|
|
12
|
+
// import { mapState } from 'vuex';
|
|
13
|
+
// import Component from '~/components/Component.vue';
|
|
14
|
+
// import Mixin from '~/components/Mixin.vue';
|
|
15
|
+
export default {
|
|
16
|
+
components: { PxStylesPreview },
|
|
17
|
+
name: 'demo-px-styles-preview',
|
|
18
|
+
// components: { Component },
|
|
19
|
+
// mixins: [ Mixin ],
|
|
20
|
+
// props: { a: { type: Boolean, default: false } },
|
|
21
|
+
// data() { return { b: 0 }; },
|
|
22
|
+
// computed: {},
|
|
23
|
+
// watch: {},
|
|
24
|
+
// mounted() {},
|
|
25
|
+
// methods: {},
|
|
26
|
+
};
|
|
27
|
+
</script>
|
|
28
|
+
|
|
29
|
+
<style lang="scss">
|
|
30
|
+
// import the library (so we can configure it)
|
|
31
|
+
@use '@thinkpixellab-public/px-styles' as *;
|
|
32
|
+
|
|
33
|
+
.demo-px-styles-preview {
|
|
34
|
+
// add configuration as needed (this is optional)
|
|
35
|
+
@include config('colors:accent', #5157bd);
|
|
36
|
+
@include config('controls:border-radius', 6px);
|
|
37
|
+
|
|
38
|
+
//@include config('font-family', 'Arial');
|
|
39
|
+
|
|
40
|
+
// initialize
|
|
41
|
+
@include init();
|
|
42
|
+
@include boilerplate($scoped: true);
|
|
43
|
+
|
|
44
|
+
// add styles here
|
|
45
|
+
}
|
|
46
|
+
</style>
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
Describe this component...
|
|
3
|
+
-->
|
|
4
|
+
<template>
|
|
5
|
+
<div :class="bem()">
|
|
6
|
+
<px-swiper :loop="true">
|
|
7
|
+
<px-swiper-slide>
|
|
8
|
+
<div class="swiper-max-width">
|
|
9
|
+
<img class="swiper-img" src="https://picsum.photos/1600/900?grayscale" />
|
|
10
|
+
</div>
|
|
11
|
+
</px-swiper-slide>
|
|
12
|
+
<px-swiper-slide>
|
|
13
|
+
<img class="swiper-img" src="https://picsum.photos/1601/900?grayscale" />
|
|
14
|
+
</px-swiper-slide>
|
|
15
|
+
<px-swiper-slide>
|
|
16
|
+
<img class="swiper-img" src="https://picsum.photos/1602/900?grayscale" />
|
|
17
|
+
</px-swiper-slide>
|
|
18
|
+
</px-swiper>
|
|
19
|
+
</div>
|
|
20
|
+
</template>
|
|
21
|
+
|
|
22
|
+
<script>
|
|
23
|
+
import PxSwiper from '../../components/PxSwiper.vue';
|
|
24
|
+
import PxSwiperSlide from '../../components/PxSwiperSlide.vue';
|
|
25
|
+
export default {
|
|
26
|
+
name: 'demo-px-swiper',
|
|
27
|
+
components: { PxSwiper, PxSwiperSlide },
|
|
28
|
+
// mixins: [ Mixin ],
|
|
29
|
+
// props: { a: { type: Boolean, default: false } },
|
|
30
|
+
// data() { return { b: 0 }; },
|
|
31
|
+
// computed: {},
|
|
32
|
+
// watch: {},
|
|
33
|
+
// mounted() {},
|
|
34
|
+
// methods: {},
|
|
35
|
+
};
|
|
36
|
+
</script>
|
|
37
|
+
|
|
38
|
+
<style lang="scss">
|
|
39
|
+
@use '../../styles/px.scss' as *;
|
|
40
|
+
|
|
41
|
+
.demo-px-swiper {
|
|
42
|
+
// add styles here
|
|
43
|
+
}
|
|
44
|
+
</style>
|