kmcom-nuxt-layers 2.2.0 → 2.2.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/layers/animations/app/components/Motion/CountUp.vue +30 -30
- package/layers/animations/app/components/Motion/Magnetic.vue +14 -14
- package/layers/animations/app/components/Motion/Marquee.vue +59 -62
- package/layers/animations/app/components/Motion/MarqueeText.vue +2 -2
- package/layers/animations/app/components/Motion/Staggered.vue +45 -49
- package/layers/animations/app/components/Motion/TextReveal.vue +21 -19
- package/layers/animations/app/components/Motion/Tilt.vue +13 -13
- package/layers/animations/app/components/Motion/VelocityEffect.vue +80 -80
- package/layers/animations/app/composables/useCountUp.ts +1 -1
- package/layers/animations/app/composables/useMarqueeVelocity.ts +2 -2
- package/layers/canvas/app/components/ShaderCanvas.vue +42 -49
- package/layers/canvas/app/composables/useRendererCapabilities.ts +29 -21
- package/layers/canvas/app/composables/useShaderTime.ts +4 -5
- package/layers/canvas/app/types/renderer.ts +5 -0
- package/layers/content/app/components/Blog/Article.vue +10 -7
- package/layers/content/app/components/Blog/Card.vue +0 -1
- package/layers/content/app/components/Blog/List.vue +2 -4
- package/layers/content/app/components/Gallery/AmbientImage.vue +0 -1
- package/layers/content/app/components/Gallery/Card.vue +0 -1
- package/layers/content/app/components/Gallery/Detail.vue +0 -2
- package/layers/content/app/components/Gallery/Grid.vue +0 -2
- package/layers/content/app/components/Gallery/ImageDetail.vue +0 -2
- package/layers/content/app/components/Gallery/Lightbox.vue +1 -6
- package/layers/content/app/components/NuxtContent/Detail.vue +3 -4
- package/layers/content/app/components/NuxtContent/List.vue +0 -1
- package/layers/content/app/components/NuxtContent/Surround.vue +0 -1
- package/layers/content/app/components/NuxtContent/Toc.vue +0 -1
- package/layers/content/app/components/Portfolio/Card.vue +0 -1
- package/layers/content/app/components/Portfolio/ColorPalette.vue +0 -1
- package/layers/content/app/components/Portfolio/Detail.vue +2 -4
- package/layers/content/app/components/Portfolio/ItemPage.vue +3 -1
- package/layers/content/app/components/Portfolio/List.vue +20 -5
- package/layers/content/app/components/Portfolio/Typography.vue +0 -1
- package/layers/content/app/components/content/Figure.vue +0 -1
- package/layers/content/app/composables/createPortfolioComposables.ts +21 -7
- package/layers/content/app/composables/useCollectionItem.ts +2 -3
- package/layers/content/app/composables/useCollectionSurround.ts +2 -3
- package/layers/content/app/composables/useContentPage.ts +0 -2
- package/layers/content/app/composables/useGalleryItems.ts +0 -2
- package/layers/content/app/composables/usePortfolioItems.ts +0 -2
- package/layers/content/app/types/app-config.d.ts +3 -1
- package/layers/content/app/types/collections.d.ts +46 -0
- package/layers/content/nuxt.config.ts +0 -1
- package/layers/core/app/components/ErrorBoundary.vue +0 -3
- package/layers/core/app/composables/useBrowser.ts +0 -1
- package/layers/core/app/composables/useCache.ts +0 -3
- package/layers/core/app/composables/useErrorLog.ts +0 -2
- package/layers/core/app/composables/useFeatures.ts +0 -3
- package/layers/core/app/composables/useLoading.ts +16 -15
- package/layers/core/app/composables/useNetworkInfo.ts +0 -2
- package/layers/core/app/composables/usePWAInfo.ts +0 -1
- package/layers/core/app/composables/useRendering.ts +0 -2
- package/layers/core/app/composables/useScreen.ts +0 -2
- package/layers/core/app/composables/useScrollGuard.ts +44 -44
- package/layers/core/app/layouts/default.vue +0 -1
- package/layers/core/app/plugins/error-handler.ts +4 -2
- package/layers/core/app/plugins/feature-detection.client.ts +4 -4
- package/layers/core/app/plugins/init.ts +4 -6
- package/layers/core/app/plugins/loading.client.ts +4 -3
- package/layers/core/app/plugins/scroll-guard.client.ts +4 -4
- package/layers/core/app/types/app-config.d.ts +1 -1
- package/layers/core/app/types/runtime-config.ts +13 -1
- package/layers/core/app/utils/helpers.ts +0 -4
- package/layers/feeds/app/app.config.ts +1 -1
- package/layers/feeds/app/plugins/feed-head.ts +4 -3
- package/layers/feeds/package.json +1 -1
- package/layers/forms/app/components/Form/Contact.vue +0 -2
- package/layers/forms/app/components/Form/Field.vue +0 -1
- package/layers/forms/app/composables/useFormSchema.ts +0 -1
- package/layers/forms/app/types/app-config.d.ts +1 -1
- package/layers/layout/app/components/Layout/Grid/Item.vue +0 -3
- package/layers/layout/app/components/Layout/Page/Container.vue +0 -4
- package/layers/layout/app/components/Layout/Page/Header.vue +0 -1
- package/layers/layout/app/components/Layout/Page/index.vue +0 -1
- package/layers/layout/app/components/Layout/Section/Gallery.vue +0 -1
- package/layers/layout/app/components/Layout/Section/Hero.vue +0 -3
- package/layers/layout/app/components/Layout/Section/Stack.vue +0 -3
- package/layers/layout/app/components/Layout/Section/Title.vue +0 -1
- package/layers/layout/app/composables/useGridConfig.ts +0 -1
- package/layers/layout/app/types/app-config.d.ts +6 -3
- package/layers/navigation/app/app.config.ts +1 -2
- package/layers/navigation/app/components/Links/Group.vue +0 -4
- package/layers/navigation/app/components/Links/Named.vue +0 -4
- package/layers/navigation/app/composables/mastNav.ts +0 -1
- package/layers/navigation/app/composables/toast.ts +0 -1
- package/layers/navigation/app/composables/useSite.ts +0 -1
- package/layers/navigation/app/utils/createModal.ts +0 -1
- package/layers/page-transitions/app/app.config.ts +1 -1
- package/layers/page-transitions/app/plugins/page-transitions.client.ts +4 -2
- package/layers/routing/app/composables/useRoutingConfig.ts +0 -1
- package/layers/routing/app/plugins/feature-flags.client.ts +4 -2
- package/layers/routing/app/plugins/scroll-routing.client.ts +4 -2
- package/layers/routing/app/types/app-config.d.ts +1 -2
- package/layers/routing/nuxt.config.ts +0 -1
- package/layers/scripts/app/app.config.ts +1 -2
- package/layers/scripts/app/composables/useAnalytics.ts +6 -6
- package/layers/scripts/app/composables/useGtm.ts +4 -4
- package/layers/scripts/app/composables/useScriptLoader.ts +12 -1
- package/layers/scroll/app/components/Motion/HorizontalScroll.vue +4 -1
- package/layers/scroll/app/components/Motion/Parallax.vue +38 -42
- package/layers/scroll/app/components/Motion/PinnedSection.vue +4 -1
- package/layers/scroll/app/components/Motion/ScrollLink.vue +26 -29
- package/layers/scroll/app/components/Motion/ScrollProgress.vue +38 -44
- package/layers/scroll/app/components/Motion/ScrollScene.vue +0 -1
- package/layers/scroll/app/components/Motion/ScrollStats.vue +19 -23
- package/layers/scroll/app/composables/useSmoothScroll.ts +21 -24
- package/layers/scroll/app/plugins/locomotive-scroll.client.ts +5 -2
- package/layers/seo/app/app.config.ts +0 -1
- package/layers/seo/app/composables/useSeoConfig.ts +0 -1
- package/layers/shader/app/components/Effect/PostProcessing.vue +3 -13
- package/layers/shader/app/components/Material/AmbientAurora.client.vue +41 -47
- package/layers/shader/app/components/Material/AmbientFlow.client.vue +47 -56
- package/layers/shader/app/components/Material/AmbientGradientMesh.client.vue +45 -51
- package/layers/shader/app/components/Material/AmbientNebula.client.vue +47 -53
- package/layers/shader/app/components/Material/AmbientOcean.client.vue +40 -46
- package/layers/shader/app/components/Material/Fresnel.client.vue +24 -29
- package/layers/shader/app/components/Material/Gradient.client.vue +61 -67
- package/layers/shader/app/components/Material/Image.client.vue +65 -71
- package/layers/shader/app/components/Material/Node.client.vue +46 -46
- package/layers/shader/app/components/Material/Noise.client.vue +48 -54
- package/layers/shader/app/components/Mesh/Plane.vue +15 -20
- package/layers/shader/app/components/Node/Color.client.vue +3 -4
- package/layers/shader/app/components/Node/Fresnel.client.vue +17 -26
- package/layers/shader/app/components/Node/Gradient.client.vue +36 -42
- package/layers/shader/app/components/Node/Mix.client.vue +13 -19
- package/layers/shader/app/components/Node/Noise.client.vue +0 -3
- package/layers/shader/app/components/Pipeline/ACESTonemap.client.vue +0 -2
- package/layers/shader/app/components/Pipeline/AddBlend.client.vue +15 -16
- package/layers/shader/app/components/Pipeline/AgedFilm.client.vue +27 -28
- package/layers/shader/app/components/Pipeline/Aurora.client.vue +37 -44
- package/layers/shader/app/components/Pipeline/BilinearGradient.client.vue +26 -33
- package/layers/shader/app/components/Pipeline/BillowNoise.client.vue +22 -23
- package/layers/shader/app/components/Pipeline/BrightnessContrast.client.vue +16 -20
- package/layers/shader/app/components/Pipeline/CellularNoise.client.vue +22 -23
- package/layers/shader/app/components/Pipeline/ChannelMixer.client.vue +28 -35
- package/layers/shader/app/components/Pipeline/ChebyshevNoiseField.client.vue +31 -31
- package/layers/shader/app/components/Pipeline/Checkerboard.client.vue +21 -23
- package/layers/shader/app/components/Pipeline/ChromaticAberration.client.vue +21 -23
- package/layers/shader/app/components/Pipeline/ChromaticScreenWaves.client.vue +31 -30
- package/layers/shader/app/components/Pipeline/Circle.client.vue +22 -23
- package/layers/shader/app/components/Pipeline/Clouds.client.vue +36 -43
- package/layers/shader/app/components/Pipeline/ColorBurnBlend.client.vue +15 -17
- package/layers/shader/app/components/Pipeline/ColorDodgeBlend.client.vue +15 -17
- package/layers/shader/app/components/Pipeline/ColourRamp.client.vue +28 -35
- package/layers/shader/app/components/Pipeline/ComplexPlaneField.client.vue +31 -38
- package/layers/shader/app/components/Pipeline/ConicGradient.client.vue +19 -21
- package/layers/shader/app/components/Pipeline/CosinePalette.client.vue +42 -49
- package/layers/shader/app/components/Pipeline/CoverageAlpha.client.vue +0 -4
- package/layers/shader/app/components/Pipeline/Cross.client.vue +28 -28
- package/layers/shader/app/components/Pipeline/CurlNoise.client.vue +26 -27
- package/layers/shader/app/components/Pipeline/DarkenBlend.client.vue +15 -17
- package/layers/shader/app/components/Pipeline/DayNightCycle.client.vue +26 -27
- package/layers/shader/app/components/Pipeline/Desaturate.client.vue +8 -15
- package/layers/shader/app/components/Pipeline/DiagonalGradient.client.vue +19 -21
- package/layers/shader/app/components/Pipeline/DiamondGradient.client.vue +19 -21
- package/layers/shader/app/components/Pipeline/DifferenceBlend.client.vue +15 -17
- package/layers/shader/app/components/Pipeline/DivideBlend.client.vue +14 -17
- package/layers/shader/app/components/Pipeline/DomainWarpedNoise.client.vue +30 -37
- package/layers/shader/app/components/Pipeline/Dots.client.vue +26 -33
- package/layers/shader/app/components/Pipeline/DuoTone.client.vue +16 -19
- package/layers/shader/app/components/Pipeline/ExclusionBlend.client.vue +14 -17
- package/layers/shader/app/components/Pipeline/ExponentialFog.client.vue +21 -23
- package/layers/shader/app/components/Pipeline/Exposure.client.vue +8 -15
- package/layers/shader/app/components/Pipeline/FBMNoise.client.vue +28 -36
- package/layers/shader/app/components/Pipeline/FilmBurn.client.vue +27 -28
- package/layers/shader/app/components/Pipeline/FilmGrain.client.vue +29 -29
- package/layers/shader/app/components/Pipeline/FisheyeRay.client.vue +11 -18
- package/layers/shader/app/components/Pipeline/Flame.client.vue +26 -27
- package/layers/shader/app/components/Pipeline/FocalGradient.client.vue +24 -25
- package/layers/shader/app/components/Pipeline/Gamma.client.vue +8 -14
- package/layers/shader/app/components/Pipeline/GodRays.client.vue +32 -39
- package/layers/shader/app/components/Pipeline/GradientNoise.client.vue +22 -22
- package/layers/shader/app/components/Pipeline/Grain.client.vue +34 -41
- package/layers/shader/app/components/Pipeline/Grid.client.vue +24 -24
- package/layers/shader/app/components/Pipeline/Halation.client.vue +22 -24
- package/layers/shader/app/components/Pipeline/Halftone.client.vue +16 -18
- package/layers/shader/app/components/Pipeline/HardLightBlend.client.vue +15 -16
- package/layers/shader/app/components/Pipeline/Haze.client.vue +22 -24
- package/layers/shader/app/components/Pipeline/Hexagon.client.vue +22 -22
- package/layers/shader/app/components/Pipeline/Hue.client.vue +8 -12
- package/layers/shader/app/components/Pipeline/Invert.client.vue +0 -1
- package/layers/shader/app/components/Pipeline/LensFlare.client.vue +27 -25
- package/layers/shader/app/components/Pipeline/LightenBlend.client.vue +15 -14
- package/layers/shader/app/components/Pipeline/LinearGradient.client.vue +17 -21
- package/layers/shader/app/components/Pipeline/LinearGradient4.client.vue +29 -33
- package/layers/shader/app/components/Pipeline/LinearToSRGB.client.vue +8 -12
- package/layers/shader/app/components/Pipeline/Marble.client.vue +41 -47
- package/layers/shader/app/components/Pipeline/MixBlend.client.vue +21 -27
- package/layers/shader/app/components/Pipeline/MonochromeTint.client.vue +16 -21
- package/layers/shader/app/components/Pipeline/MultiplyBlend.client.vue +15 -16
- package/layers/shader/app/components/Pipeline/NoisyGradient.client.vue +34 -40
- package/layers/shader/app/components/Pipeline/NoisyGradientBlend.client.vue +54 -60
- package/layers/shader/app/components/Pipeline/OverlayBlend.client.vue +15 -16
- package/layers/shader/app/components/Pipeline/PaperTexture.client.vue +22 -24
- package/layers/shader/app/components/Pipeline/Polygon.client.vue +32 -39
- package/layers/shader/app/components/Pipeline/Posterise.client.vue +8 -14
- package/layers/shader/app/components/Pipeline/RadialGradient.client.vue +18 -24
- package/layers/shader/app/components/Pipeline/RayAutoOrbit.client.vue +16 -18
- package/layers/shader/app/components/Pipeline/RayMouseOrbit.client.vue +16 -18
- package/layers/shader/app/components/Pipeline/RayRotateX.client.vue +8 -14
- package/layers/shader/app/components/Pipeline/RayRotateY.client.vue +8 -14
- package/layers/shader/app/components/Pipeline/RayRotateZ.client.vue +8 -14
- package/layers/shader/app/components/Pipeline/RayTiltBasis.client.vue +21 -22
- package/layers/shader/app/components/Pipeline/RaymarchTunnel.client.vue +34 -40
- package/layers/shader/app/components/Pipeline/Rectangle.client.vue +30 -36
- package/layers/shader/app/components/Pipeline/ReinhardTonemap.client.vue +0 -3
- package/layers/shader/app/components/Pipeline/RidgedNoise.client.vue +22 -22
- package/layers/shader/app/components/Pipeline/Ring.client.vue +26 -32
- package/layers/shader/app/components/Pipeline/RingField.client.vue +36 -33
- package/layers/shader/app/components/Pipeline/RisographGrain.client.vue +29 -35
- package/layers/shader/app/components/Pipeline/RotatedGradientBlend.client.vue +29 -35
- package/layers/shader/app/components/Pipeline/SDFColourMask.client.vue +15 -18
- package/layers/shader/app/components/Pipeline/SDFRadialMask.client.vue +16 -18
- package/layers/shader/app/components/Pipeline/SRGBToLinear.client.vue +8 -14
- package/layers/shader/app/components/Pipeline/Saturation.client.vue +8 -14
- package/layers/shader/app/components/Pipeline/Scanlines.client.vue +21 -22
- package/layers/shader/app/components/Pipeline/ScreenBlend.client.vue +15 -16
- package/layers/shader/app/components/Pipeline/ShaderDebugger.client.vue +28 -29
- package/layers/shader/app/components/Pipeline/SimplexNoise.client.vue +25 -32
- package/layers/shader/app/components/Pipeline/SkyAtmosphere.client.vue +37 -44
- package/layers/shader/app/components/Pipeline/SoftLightBlend.client.vue +15 -16
- package/layers/shader/app/components/Pipeline/SolidColour.client.vue +7 -16
- package/layers/shader/app/components/Pipeline/SplitTone.client.vue +27 -28
- package/layers/shader/app/components/Pipeline/Star.client.vue +31 -37
- package/layers/shader/app/components/Pipeline/Starfield.client.vue +29 -27
- package/layers/shader/app/components/Pipeline/Stripes.client.vue +28 -27
- package/layers/shader/app/components/Pipeline/SubtractBlend.client.vue +15 -16
- package/layers/shader/app/components/Pipeline/TanhTonemap.client.vue +8 -17
- package/layers/shader/app/components/Pipeline/Threshold.client.vue +8 -14
- package/layers/shader/app/components/Pipeline/Tint.client.vue +16 -18
- package/layers/shader/app/components/Pipeline/Triangle.client.vue +22 -22
- package/layers/shader/app/components/Pipeline/UVAspectCorrect.client.vue +0 -2
- package/layers/shader/app/components/Pipeline/UVBreath.client.vue +16 -18
- package/layers/shader/app/components/Pipeline/UVBulge.client.vue +16 -18
- package/layers/shader/app/components/Pipeline/UVClamp.client.vue +0 -3
- package/layers/shader/app/components/Pipeline/UVColumnOffset.client.vue +16 -18
- package/layers/shader/app/components/Pipeline/UVFlipX.client.vue +0 -3
- package/layers/shader/app/components/Pipeline/UVFlipXY.client.vue +0 -3
- package/layers/shader/app/components/Pipeline/UVFlipY.client.vue +0 -3
- package/layers/shader/app/components/Pipeline/UVFractBand.client.vue +16 -18
- package/layers/shader/app/components/Pipeline/UVMousePull.client.vue +8 -14
- package/layers/shader/app/components/Pipeline/UVNoiseRotate.client.vue +21 -27
- package/layers/shader/app/components/Pipeline/UVNoiseWarp.client.vue +21 -22
- package/layers/shader/app/components/Pipeline/UVOrbit.client.vue +8 -14
- package/layers/shader/app/components/Pipeline/UVParallax.client.vue +8 -18
- package/layers/shader/app/components/Pipeline/UVPixelate.client.vue +7 -14
- package/layers/shader/app/components/Pipeline/UVPulse.client.vue +16 -18
- package/layers/shader/app/components/Pipeline/UVRipple.client.vue +26 -26
- package/layers/shader/app/components/Pipeline/UVRotate.client.vue +16 -22
- package/layers/shader/app/components/Pipeline/UVScale.client.vue +16 -22
- package/layers/shader/app/components/Pipeline/UVScroll.client.vue +12 -18
- package/layers/shader/app/components/Pipeline/UVScrollX.client.vue +8 -14
- package/layers/shader/app/components/Pipeline/UVScrollY.client.vue +8 -14
- package/layers/shader/app/components/Pipeline/UVShear.client.vue +16 -18
- package/layers/shader/app/components/Pipeline/UVSineWarpXY.client.vue +18 -24
- package/layers/shader/app/components/Pipeline/UVSwapAxes.client.vue +0 -3
- package/layers/shader/app/components/Pipeline/UVTile.client.vue +12 -18
- package/layers/shader/app/components/Pipeline/UVTwirl.client.vue +16 -18
- package/layers/shader/app/components/Pipeline/UVWarp.client.vue +21 -22
- package/layers/shader/app/components/Pipeline/VHSBleed.client.vue +27 -28
- package/layers/shader/app/components/Pipeline/ValueNoise.client.vue +22 -22
- package/layers/shader/app/components/Pipeline/Vibrance.client.vue +11 -17
- package/layers/shader/app/components/Pipeline/Vignette.client.vue +14 -20
- package/layers/shader/app/components/Pipeline/VoronoiEdges.client.vue +29 -28
- package/layers/shader/app/components/Pipeline/Water.client.vue +31 -37
- package/layers/shader/app/components/Pipeline/WaveBendLayer.client.vue +26 -32
- package/layers/shader/app/components/Pipeline/WaveColourLayer.client.vue +37 -36
- package/layers/shader/app/components/Pipeline/WhiteBalance.client.vue +23 -26
- package/layers/shader/app/components/Pipeline/Wood.client.vue +34 -40
- package/layers/shader/app/components/Preset/Aurora.client.vue +0 -7
- package/layers/shader/app/components/Preset/Flow.client.vue +15 -23
- package/layers/shader/app/components/Preset/GradientMesh.client.vue +15 -23
- package/layers/shader/app/components/Preset/Nebula.client.vue +15 -25
- package/layers/shader/app/components/Preset/Ocean.client.vue +15 -24
- package/layers/shader/app/components/Preset/ThemeAurora.client.vue +38 -47
- package/layers/shader/app/components/Preset/ThemeBubble.client.vue +38 -47
- package/layers/shader/app/components/Preset/ThemeFlow.client.vue +38 -47
- package/layers/shader/app/components/Preset/ThemeGradient.client.vue +38 -47
- package/layers/shader/app/components/Preset/ThemeLavaLamp.client.vue +38 -47
- package/layers/shader/app/components/Preset/ThemePlasma.client.vue +38 -47
- package/layers/shader/app/components/Preset/ThemeWave.client.vue +38 -47
- package/layers/shader/app/components/Shader/Background.client.vue +109 -75
- package/layers/shader/app/components/Shader/Debug.vue +4 -14
- package/layers/shader/app/components/Shader/Host.client.vue +7 -9
- package/layers/shader/app/components/Shader/Material.client.vue +8 -20
- package/layers/shader/app/components/Shader/Pipeline.client.vue +0 -6
- package/layers/shader/app/components/Shader/Runtime.client.vue +0 -5
- package/layers/shader/app/composables/useAmbientMaterials.ts +4 -9
- package/layers/shader/app/composables/useCSSColourUniform.ts +0 -4
- package/layers/shader/app/composables/useCSSFloatUniform.ts +0 -3
- package/layers/shader/app/composables/useShader.ts +1 -4
- package/layers/shader/app/composables/useShaderColor.ts +4 -6
- package/layers/shader/app/composables/useShaderFloat.ts +1 -3
- package/layers/shader/app/composables/useShaderGraph.ts +4 -5
- package/layers/shader/app/composables/useShaderRuntime.ts +0 -5
- package/layers/shader/app/composables/useShaderVec2.ts +4 -8
- package/layers/shader/app/composables/useSunDirectionUniform.ts +0 -6
- package/layers/shader/app/composables/useThemeColors.ts +0 -1
- package/layers/shader/app/composables/useUniforms.ts +25 -9
- package/layers/shader/app/plugins/shader.client.ts +4 -3
- package/layers/shader/app/shaders/common/blend.ts +2 -4
- package/layers/shader/app/shaders/common/complex.ts +0 -2
- package/layers/shader/app/shaders/common/effects.ts +5 -13
- package/layers/shader/app/shaders/common/grain.ts +2 -7
- package/layers/shader/app/shaders/common/lighting.ts +0 -3
- package/layers/shader/app/shaders/common/math.ts +12 -8
- package/layers/shader/app/shaders/common/noise.ts +48 -48
- package/layers/shader/app/shaders/common/noiseHelpers.ts +6 -6
- package/layers/shader/app/shaders/common/palette.ts +10 -11
- package/layers/shader/app/shaders/common/patterns.ts +1 -4
- package/layers/shader/app/shaders/common/sdf.ts +11 -7
- package/layers/shader/app/shaders/common/shapes.ts +25 -15
- package/layers/shader/app/shaders/common/tonemapping.ts +0 -2
- package/layers/shader/app/shaders/common/uv.ts +20 -29
- package/layers/shader/app/shaders/createMaterial.ts +2 -5
- package/layers/shader/app/shaders/layers/aurora.ts +14 -17
- package/layers/shader/app/shaders/layers/meshGradient.ts +13 -16
- package/layers/shader/app/shaders/layers/paperShading.ts +15 -19
- package/layers/shader/app/shaders/layers/shaderGradient.ts +18 -23
- package/layers/shader/app/shaders/layers/stripe.ts +14 -17
- package/layers/shader/app/shaders/types.ts +9 -1
- package/layers/shader/app/types/app-config.d.ts +1 -1
- package/layers/shader/app/types/tsl.ts +0 -1
- package/layers/shader/app/types/uniforms.ts +0 -1
- package/layers/shader/app/utils/tsl/animation.ts +50 -52
- package/layers/shader/app/utils/tsl/color.ts +20 -19
- package/layers/shader/app/utils/tsl/noise.ts +10 -12
- package/layers/shader/app/utils/tsl/oklch.ts +6 -7
- package/layers/shader/app/utils/tsl/patterns.ts +4 -6
- package/layers/shader/app/utils/tsl/tween.ts +2 -4
- package/layers/shader/app/utils/tsl/uv.ts +6 -6
- package/layers/theme/app/components/ThemePicker/AccentButton.vue +1 -3
- package/layers/theme/app/components/ThemePicker/Colors.vue +0 -1
- package/layers/theme/app/composables/useAccentColor.ts +0 -1
- package/layers/theme/app/plugins/theme.client.ts +4 -3
- package/layers/theme/app/types/app-config.d.ts +1 -2
- package/layers/transitions/app/components/Motion/Transition.vue +15 -22
- package/layers/typography/app/components/Typography/CodeBlock.vue +16 -19
- package/layers/typography/app/components/Typography/Headline.vue +46 -49
- package/layers/typography/app/components/Typography/HeadlineScreen.vue +36 -40
- package/layers/typography/app/components/Typography/QuoteBlock.vue +3 -4
- package/layers/typography/app/components/Typography/TextStroke.vue +15 -20
- package/layers/typography/app/components/Typography/index.vue +0 -4
- package/layers/typography/app/composables/typography.ts +9 -11
- package/layers/visual/app/app.config.ts +1 -2
- package/layers/visual/app/components/Accent/Blob.vue +0 -3
- package/layers/visual/app/components/Accent/Scene.vue +12 -17
- package/layers/visual/app/components/Base/Modal.vue +0 -1
- package/layers/visual/app/components/Gradient/Background.vue +10 -13
- package/layers/visual/app/components/Gradient/Text.vue +10 -13
- package/layers/visual/app/components/Media/Picture.vue +0 -1
- package/layers/visual/app/components/Progress/Bar.vue +0 -1
- package/layers/visual/app/components/Progress/Circular.vue +0 -1
- package/layers/visual/app/components/Tint/Overlay.vue +0 -2
- package/layers/visual/app/composables/gradient.ts +6 -11
- package/layers/visual/app/composables/picture.ts +0 -1
- package/layers/visual/app/composables/tint.ts +0 -1
- package/layers/visual/app/types/media.ts +0 -1
- package/package.json +2 -1
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
/* eslint-disable @typescript-eslint/ban-ts-comment */
|
|
2
|
-
// @ts-nocheck
|
|
3
1
|
import { abs, float, floor, Fn, fract, length, min, mod, sin, vec2 } from 'three/tsl'
|
|
4
2
|
|
|
5
3
|
import type { TSLNode } from '../../types'
|
|
@@ -18,7 +16,7 @@ export const checker = Fn(([uv, scale]: [TSLNode, TSLNode]) => {
|
|
|
18
16
|
* Grid lines pattern
|
|
19
17
|
*/
|
|
20
18
|
export const grid = Fn(([uv, scale, lineWidth]: [TSLNode, TSLNode, TSLNode]) => {
|
|
21
|
-
const scaledUV = fract(uv.mul(scale))
|
|
19
|
+
const scaledUV: TSLNode = fract(uv.mul(scale))
|
|
22
20
|
const halfWidth = lineWidth.mul(0.5)
|
|
23
21
|
const xLine = scaledUV.x.lessThan(halfWidth).or(scaledUV.x.greaterThan(float(1.0).sub(halfWidth)))
|
|
24
22
|
const yLine = scaledUV.y.lessThan(halfWidth).or(scaledUV.y.greaterThan(float(1.0).sub(halfWidth)))
|
|
@@ -117,7 +115,7 @@ export const bricks = Fn(([uv, scale, ratio, gap]: [TSLNode, TSLNode, TSLNode, T
|
|
|
117
115
|
export const concentricCircles = Fn(
|
|
118
116
|
([uv, center, scale, width]: [TSLNode, TSLNode, TSLNode, TSLNode]) => {
|
|
119
117
|
const dist = length(uv.sub(center))
|
|
120
|
-
const rings = fract(dist.mul(scale))
|
|
118
|
+
const rings: TSLNode = fract(dist.mul(scale))
|
|
121
119
|
return rings.lessThan(width).select(float(1.0), float(0.0))
|
|
122
120
|
}
|
|
123
121
|
)
|
|
@@ -142,7 +140,7 @@ export const radialLines = Fn(
|
|
|
142
140
|
*/
|
|
143
141
|
export const diamonds = Fn(([uv, scale]: [TSLNode, TSLNode]) => {
|
|
144
142
|
const scaledUV = fract(uv.mul(scale))
|
|
145
|
-
const centered = abs(scaledUV.sub(0.5))
|
|
143
|
+
const centered: TSLNode = abs(scaledUV.sub(0.5))
|
|
146
144
|
return centered.x.add(centered.y).lessThan(0.5).select(float(1.0), float(0.0))
|
|
147
145
|
})
|
|
148
146
|
|
|
@@ -151,7 +149,7 @@ export const diamonds = Fn(([uv, scale]: [TSLNode, TSLNode]) => {
|
|
|
151
149
|
*/
|
|
152
150
|
export const triangles = Fn(([uv, scale]: [TSLNode, TSLNode]) => {
|
|
153
151
|
const scaledUV = uv.mul(scale)
|
|
154
|
-
const p = fract(scaledUV)
|
|
152
|
+
const p: TSLNode = fract(scaledUV)
|
|
155
153
|
const row = floor(scaledUV.y)
|
|
156
154
|
const flip = mod(row, 2.0)
|
|
157
155
|
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
/* eslint-disable no-restricted-syntax */
|
|
2
|
-
/* eslint-disable max-params */
|
|
3
1
|
/**
|
|
4
2
|
* GPU-friendly uniform tweening via requestAnimationFrame.
|
|
5
3
|
* Updates uniform .value each frame -- no shader recompilation.
|
|
@@ -43,9 +41,9 @@ export function tweenUniform(
|
|
|
43
41
|
|
|
44
42
|
if (rawT < 1) {
|
|
45
43
|
requestAnimationFrame(tick)
|
|
46
|
-
|
|
47
|
-
resolvePromise()
|
|
44
|
+
return
|
|
48
45
|
}
|
|
46
|
+
resolvePromise()
|
|
49
47
|
}
|
|
50
48
|
|
|
51
49
|
requestAnimationFrame(tick)
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
/* eslint-disable @typescript-eslint/ban-ts-comment */
|
|
2
|
-
// @ts-nocheck
|
|
3
1
|
import { atan, cos, float, Fn, fract, length, sin, vec2 } from 'three/tsl'
|
|
4
2
|
|
|
5
3
|
import type { TSLNode } from '../../types'
|
|
@@ -48,17 +46,19 @@ export const polarUV = Fn(([uv, center]: [TSLNode, TSLNode]) => {
|
|
|
48
46
|
* Convert polar coordinates back to cartesian
|
|
49
47
|
*/
|
|
50
48
|
export const cartesianUV = Fn(([polar, center]: [TSLNode, TSLNode]) => {
|
|
51
|
-
const angle = polar.x.sub(0.5).mul(Math.PI * 2)
|
|
49
|
+
const angle: TSLNode = polar.x.sub(0.5).mul(Math.PI * 2)
|
|
52
50
|
const radius = polar.y
|
|
53
|
-
|
|
51
|
+
const x: TSLNode = cos(angle).mul(radius)
|
|
52
|
+
const y: TSLNode = sin(angle).mul(radius)
|
|
53
|
+
return vec2(x, y).add(center)
|
|
54
54
|
})
|
|
55
55
|
|
|
56
56
|
/**
|
|
57
57
|
* Wave distortion on UV
|
|
58
58
|
*/
|
|
59
59
|
export const waveUV = Fn(([uv, freq, amp, time]: [TSLNode, TSLNode, TSLNode, TSLNode]) => {
|
|
60
|
-
const waveX = sin(uv.y.mul(freq).add(time)).mul(amp)
|
|
61
|
-
const waveY = sin(uv.x.mul(freq).add(time)).mul(amp)
|
|
60
|
+
const waveX: TSLNode = sin(uv.y.mul(freq).add(time)).mul(amp)
|
|
61
|
+
const waveY: TSLNode = sin(uv.x.mul(freq).add(time)).mul(amp)
|
|
62
62
|
return uv.add(vec2(waveX, waveY))
|
|
63
63
|
})
|
|
64
64
|
|
|
@@ -36,8 +36,6 @@
|
|
|
36
36
|
</script>
|
|
37
37
|
|
|
38
38
|
<template>
|
|
39
|
-
<!-- eslint-disable vue/v-on-handler-style -->
|
|
40
|
-
|
|
41
39
|
<button
|
|
42
40
|
class="size-8 rounded-full ring-1 ring-offset-2 transition-shadow duration-200"
|
|
43
41
|
:class="[
|
|
@@ -48,6 +46,6 @@
|
|
|
48
46
|
:style="bgStyle"
|
|
49
47
|
:aria-label="`Set accent color to ${color}`"
|
|
50
48
|
:aria-pressed="active"
|
|
51
|
-
@click="emit('select', color)"
|
|
49
|
+
@click="() => emit('select', color)"
|
|
52
50
|
/>
|
|
53
51
|
</template>
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
/* eslint-disable no-restricted-syntax */
|
|
2
|
-
/* eslint-disable @typescript-eslint/consistent-type-assertions */
|
|
3
1
|
import type { AccentColor, PreferenceOverride } from '#layers/theme/app/types/theme'
|
|
4
2
|
|
|
5
|
-
export default defineNuxtPlugin(
|
|
3
|
+
export default defineNuxtPlugin({
|
|
4
|
+
name: 'theme:theme',
|
|
5
|
+
setup() {
|
|
6
6
|
const { setAccent, activeAccent } = useAccentColor()
|
|
7
7
|
const { setContrastOverride, effectiveHighContrast } = useThemeContrast()
|
|
8
8
|
const { setMotionOverride, effectiveReducedMotion } = useThemeMotion()
|
|
@@ -54,4 +54,5 @@ export default defineNuxtPlugin(() => {
|
|
|
54
54
|
},
|
|
55
55
|
{ immediate: true }
|
|
56
56
|
)
|
|
57
|
+
},
|
|
57
58
|
})
|
|
@@ -1,23 +1,16 @@
|
|
|
1
|
-
<!-- eslint-disable vue/no-unused-properties -->
|
|
2
|
-
<!-- eslint-disable vue/define-props-destructuring -->
|
|
3
1
|
<script setup lang="ts">
|
|
4
2
|
// Props
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
duration: 300,
|
|
17
|
-
delay: 0,
|
|
18
|
-
easing: 'ease-out',
|
|
19
|
-
}
|
|
20
|
-
)
|
|
3
|
+
const {
|
|
4
|
+
name = 'fade',
|
|
5
|
+
duration = 300,
|
|
6
|
+
delay = 0,
|
|
7
|
+
easing = 'ease-out',
|
|
8
|
+
} = defineProps<{
|
|
9
|
+
name?: string
|
|
10
|
+
duration?: number
|
|
11
|
+
delay?: number
|
|
12
|
+
easing?: string
|
|
13
|
+
}>()
|
|
21
14
|
|
|
22
15
|
// State
|
|
23
16
|
const isVisible = ref(false)
|
|
@@ -25,14 +18,14 @@
|
|
|
25
18
|
|
|
26
19
|
// Computed classes
|
|
27
20
|
const transitionClass = computed(() => {
|
|
28
|
-
return `transition-${
|
|
21
|
+
return `transition-${name}`
|
|
29
22
|
})
|
|
30
23
|
|
|
31
24
|
const style = computed(() => {
|
|
32
25
|
return {
|
|
33
|
-
transitionDuration: `${
|
|
34
|
-
transitionDelay: `${
|
|
35
|
-
transitionTimingFunction:
|
|
26
|
+
transitionDuration: `${duration}ms`,
|
|
27
|
+
transitionDelay: `${delay}ms`,
|
|
28
|
+
transitionTimingFunction: easing,
|
|
36
29
|
}
|
|
37
30
|
})
|
|
38
31
|
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
<!-- eslint-disable vue/require-default-prop -->
|
|
2
|
-
<!-- eslint-disable vue/define-props-destructuring -->
|
|
3
1
|
<script lang="ts" setup>
|
|
4
2
|
import { useColor } from '../../composables/color'
|
|
5
3
|
import type { UiColors } from '../../types/colors'
|
|
@@ -7,19 +5,18 @@
|
|
|
7
5
|
|
|
8
6
|
defineOptions({ inheritAttrs: false })
|
|
9
7
|
|
|
10
|
-
const
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
)
|
|
22
|
-
const colorClass = useColor(props.color, 'text')
|
|
8
|
+
const {
|
|
9
|
+
language,
|
|
10
|
+
color = 'default',
|
|
11
|
+
size,
|
|
12
|
+
class: classProp = '',
|
|
13
|
+
} = defineProps<{
|
|
14
|
+
language?: string
|
|
15
|
+
color?: UiColors
|
|
16
|
+
size?: FontSize
|
|
17
|
+
class?: string
|
|
18
|
+
}>()
|
|
19
|
+
const colorClass = useColor(color, 'text')
|
|
23
20
|
</script>
|
|
24
21
|
|
|
25
22
|
<template>
|
|
@@ -27,16 +24,16 @@
|
|
|
27
24
|
tag="pre"
|
|
28
25
|
v-bind="{
|
|
29
26
|
...$attrs,
|
|
30
|
-
...(
|
|
31
|
-
...(
|
|
27
|
+
...(size !== undefined && { size: size }),
|
|
28
|
+
...(language !== undefined && { 'data-language': language }),
|
|
32
29
|
}"
|
|
33
30
|
class="overflow-x-auto"
|
|
34
|
-
:class="[
|
|
31
|
+
:class="[classProp]"
|
|
35
32
|
>
|
|
36
33
|
<Typography
|
|
37
34
|
tag="code"
|
|
38
35
|
class="font-mono"
|
|
39
|
-
:class="[colorClass,
|
|
36
|
+
:class="[colorClass, language ? `language-${language}` : '']"
|
|
40
37
|
>
|
|
41
38
|
<slot />
|
|
42
39
|
</Typography>
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
<!-- eslint-disable vue/require-default-prop -->
|
|
2
|
-
<!-- eslint-disable vue/define-props-destructuring -->
|
|
3
1
|
<script lang="ts" setup>
|
|
4
2
|
import { useColor } from '../../composables/color'
|
|
5
3
|
import { useTypography } from '../../composables/typography'
|
|
@@ -17,36 +15,35 @@
|
|
|
17
15
|
|
|
18
16
|
defineOptions({ inheritAttrs: false })
|
|
19
17
|
|
|
20
|
-
const
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
)
|
|
46
|
-
const tag = computed(() => `h${props.level}` as const)
|
|
18
|
+
const {
|
|
19
|
+
level = 1,
|
|
20
|
+
weight = 'font-bold',
|
|
21
|
+
width = 'font-stretch-normal',
|
|
22
|
+
slant = 'normal',
|
|
23
|
+
leading = 'leading-tight',
|
|
24
|
+
tracking = 'tracking-tight',
|
|
25
|
+
align = 'left',
|
|
26
|
+
transform = 'none',
|
|
27
|
+
color,
|
|
28
|
+
size,
|
|
29
|
+
class: classProp = '',
|
|
30
|
+
} = defineProps<{
|
|
31
|
+
level?: 1 | 2 | 3 | 4 | 5 | 6
|
|
32
|
+
weight?: FontWeight
|
|
33
|
+
width?: FontWidth
|
|
34
|
+
slant?: FontSlant
|
|
35
|
+
leading?: FontLeading
|
|
36
|
+
tracking?: FontTracking
|
|
37
|
+
align?: TextAlign
|
|
38
|
+
transform?: TextTransform
|
|
39
|
+
color?: UiColors
|
|
40
|
+
size?: FontSize
|
|
41
|
+
class?: string
|
|
42
|
+
}>()
|
|
43
|
+
const tag = computed(() => `h${level}` as const)
|
|
47
44
|
|
|
48
45
|
const sizeClass = computed(() => {
|
|
49
|
-
if (
|
|
46
|
+
if (size) return null
|
|
50
47
|
|
|
51
48
|
const sizes: Record<number, string> = {
|
|
52
49
|
1: 'text-4xl sm:text-5xl',
|
|
@@ -56,34 +53,34 @@
|
|
|
56
53
|
5: 'text-lg sm:text-xl',
|
|
57
54
|
6: 'text-base sm:text-lg',
|
|
58
55
|
}
|
|
59
|
-
return sizes[
|
|
56
|
+
return sizes[level]
|
|
60
57
|
})
|
|
61
58
|
|
|
62
59
|
const { classes } = useTypography({
|
|
63
|
-
weight:
|
|
64
|
-
width:
|
|
65
|
-
slant:
|
|
66
|
-
leading:
|
|
67
|
-
tracking:
|
|
68
|
-
align:
|
|
69
|
-
transform:
|
|
70
|
-
...(
|
|
60
|
+
weight: weight,
|
|
61
|
+
width: width,
|
|
62
|
+
slant: slant,
|
|
63
|
+
leading: leading,
|
|
64
|
+
tracking: tracking,
|
|
65
|
+
align: align,
|
|
66
|
+
transform: transform,
|
|
67
|
+
...(size !== undefined && { size: size }),
|
|
71
68
|
})
|
|
72
|
-
const colorClass = useColor(
|
|
69
|
+
const colorClass = useColor(color, 'text')
|
|
73
70
|
</script>
|
|
74
71
|
|
|
75
72
|
<template>
|
|
76
73
|
<Typography
|
|
77
74
|
:tag
|
|
78
|
-
:weight
|
|
79
|
-
:width
|
|
80
|
-
:slant
|
|
81
|
-
:leading
|
|
82
|
-
:tracking
|
|
83
|
-
:align
|
|
84
|
-
:transform
|
|
85
|
-
:class="[sizeClass, classes, colorClass,
|
|
86
|
-
v-bind="{ ...(
|
|
75
|
+
:weight
|
|
76
|
+
:width
|
|
77
|
+
:slant
|
|
78
|
+
:leading
|
|
79
|
+
:tracking
|
|
80
|
+
:align
|
|
81
|
+
:transform
|
|
82
|
+
:class="[sizeClass, classes, colorClass, classProp]"
|
|
83
|
+
v-bind="{ ...(size !== undefined && { size: size }), ...$attrs }"
|
|
87
84
|
>
|
|
88
85
|
<slot />
|
|
89
86
|
</Typography>
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
<!-- eslint-disable vue/require-default-prop -->
|
|
2
|
-
<!-- eslint-disable vue/define-props-destructuring -->
|
|
3
1
|
<script lang="ts" setup>
|
|
4
2
|
import { useColor } from '../../composables/color'
|
|
5
3
|
import { useTypography } from '../../composables/typography'
|
|
@@ -17,35 +15,33 @@
|
|
|
17
15
|
|
|
18
16
|
defineOptions({ inheritAttrs: false })
|
|
19
17
|
|
|
20
|
-
const
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
}
|
|
46
|
-
)
|
|
18
|
+
const {
|
|
19
|
+
level = 1,
|
|
20
|
+
size = 'screen-xxl',
|
|
21
|
+
weight = 'font-bold',
|
|
22
|
+
width = 'font-stretch-normal',
|
|
23
|
+
slant = 'normal',
|
|
24
|
+
leading = 'leading-tight',
|
|
25
|
+
tracking = 'tracking-tight',
|
|
26
|
+
align = 'left',
|
|
27
|
+
transform = 'none',
|
|
28
|
+
color,
|
|
29
|
+
class: classProp = '',
|
|
30
|
+
} = defineProps<{
|
|
31
|
+
level?: 1 | 2 | 3 | 4 | 5 | 6
|
|
32
|
+
size?: FontScreenSize
|
|
33
|
+
weight?: FontWeight
|
|
34
|
+
width?: FontWidth
|
|
35
|
+
slant?: FontSlant
|
|
36
|
+
leading?: FontLeading
|
|
37
|
+
tracking?: FontTracking
|
|
38
|
+
align?: TextAlign
|
|
39
|
+
transform?: TextTransform
|
|
40
|
+
color?: UiColors
|
|
41
|
+
class?: string
|
|
42
|
+
}>()
|
|
47
43
|
|
|
48
|
-
const tag = computed(() => `h${
|
|
44
|
+
const tag = computed(() => `h${level}` as const)
|
|
49
45
|
|
|
50
46
|
const sizeMap: Record<string, string> = {
|
|
51
47
|
screen: 'text-screen',
|
|
@@ -53,23 +49,23 @@
|
|
|
53
49
|
'screen-xxl': 'text-screen-xxl',
|
|
54
50
|
'screen-xxxl': 'text-screen-xxxl',
|
|
55
51
|
}
|
|
56
|
-
const sizeClass = computed(() => sizeMap[
|
|
52
|
+
const sizeClass = computed(() => sizeMap[size] ?? 'text-screen-xxl')
|
|
57
53
|
|
|
58
54
|
const { classes } = useTypography({
|
|
59
|
-
weight:
|
|
60
|
-
width:
|
|
61
|
-
slant:
|
|
62
|
-
leading:
|
|
63
|
-
tracking:
|
|
64
|
-
align:
|
|
65
|
-
transform:
|
|
55
|
+
weight: weight,
|
|
56
|
+
width: width,
|
|
57
|
+
slant: slant,
|
|
58
|
+
leading: leading,
|
|
59
|
+
tracking: tracking,
|
|
60
|
+
align: align,
|
|
61
|
+
transform: transform,
|
|
66
62
|
})
|
|
67
63
|
|
|
68
|
-
const colorClass = useColor(
|
|
64
|
+
const colorClass = useColor(color, 'text')
|
|
69
65
|
</script>
|
|
70
66
|
|
|
71
67
|
<template>
|
|
72
|
-
<component :is="tag" :class="[sizeClass, classes, colorClass,
|
|
68
|
+
<component :is="tag" :class="[sizeClass, classes, colorClass, classProp]" v-bind="$attrs">
|
|
73
69
|
<slot />
|
|
74
70
|
</component>
|
|
75
71
|
</template>
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
<!-- eslint-disable vue/define-props-destructuring -->
|
|
2
1
|
<script setup lang="ts">
|
|
3
2
|
import { useColor } from '../../composables/color'
|
|
4
3
|
import type { UiColors } from '../../types/colors'
|
|
@@ -6,15 +5,15 @@
|
|
|
6
5
|
|
|
7
6
|
defineOptions({ inheritAttrs: false })
|
|
8
7
|
|
|
9
|
-
const
|
|
10
|
-
const colorClass = useColor(
|
|
8
|
+
const { color, size } = defineProps<{ color?: UiColors; size?: FontSize }>()
|
|
9
|
+
const colorClass = useColor(color, 'text')
|
|
11
10
|
</script>
|
|
12
11
|
|
|
13
12
|
<template>
|
|
14
13
|
<Typography
|
|
15
14
|
tag="blockquote"
|
|
16
15
|
:class="colorClass"
|
|
17
|
-
v-bind="{ ...(
|
|
16
|
+
v-bind="{ ...(size !== undefined && { size: size }), ...$attrs }"
|
|
18
17
|
>
|
|
19
18
|
<slot />
|
|
20
19
|
</Typography>
|
|
@@ -1,32 +1,27 @@
|
|
|
1
|
-
<!-- eslint-disable vue/define-props-destructuring -->
|
|
2
1
|
<script lang="ts" setup>
|
|
3
|
-
const
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
tag: 'div',
|
|
18
|
-
}
|
|
19
|
-
)
|
|
2
|
+
const {
|
|
3
|
+
strokeWidth = 1.5,
|
|
4
|
+
strokeColor = 'currentColor',
|
|
5
|
+
fill = 'none',
|
|
6
|
+
linejoin = 'round',
|
|
7
|
+
tag = 'div',
|
|
8
|
+
} = defineProps<{
|
|
9
|
+
text: string
|
|
10
|
+
strokeWidth?: number
|
|
11
|
+
strokeColor?: string
|
|
12
|
+
fill?: string
|
|
13
|
+
linejoin?: 'round' | 'miter' | 'bevel'
|
|
14
|
+
tag?: string
|
|
15
|
+
}>()
|
|
20
16
|
const id = useId()
|
|
21
17
|
const contrast = usePreferredContrast()
|
|
22
18
|
|
|
23
19
|
const effectiveStrokeWidth = computed(() =>
|
|
24
|
-
contrast.value === 'more' ?
|
|
20
|
+
contrast.value === 'more' ? strokeWidth * 1.5 : strokeWidth
|
|
25
21
|
)
|
|
26
22
|
</script>
|
|
27
23
|
|
|
28
24
|
<template>
|
|
29
|
-
<!-- eslint-disable vue/no-duplicate-attr-inheritance -->
|
|
30
25
|
<component
|
|
31
26
|
:is="tag"
|
|
32
27
|
class="text-stroke inline-grid leading-none *:[grid-area:1/1]"
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
<!-- eslint-disable vue/define-props-destructuring -->
|
|
2
|
-
<!-- eslint-disable vue/require-default-prop -->
|
|
3
|
-
<!-- eslint-disable vue/no-unused-properties -->
|
|
4
1
|
<script lang="ts" setup>
|
|
5
2
|
import { useColor } from '../../composables/color'
|
|
6
3
|
import { useTypography } from '../../composables/typography'
|
|
@@ -47,7 +44,6 @@
|
|
|
47
44
|
</script>
|
|
48
45
|
|
|
49
46
|
<template>
|
|
50
|
-
<!-- eslint-disable-next-line vue/no-duplicate-attr-inheritance -->
|
|
51
47
|
<component :is="tag" :class="[classes, colorClass]" v-bind="$attrs">
|
|
52
48
|
<slot />
|
|
53
49
|
</component>
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/* eslint-disable no-nested-ternary */
|
|
2
1
|
import type {
|
|
3
2
|
FontLeading,
|
|
4
3
|
FontSize,
|
|
@@ -23,16 +22,19 @@ function normalizeAxis(
|
|
|
23
22
|
const { prefix = '', fallback = '', numericFormatter } = options
|
|
24
23
|
|
|
25
24
|
if (typeof value === 'number') {
|
|
26
|
-
return numericFormatter
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
? `${prefix}-[${value}]`
|
|
30
|
-
: `[${value}]`
|
|
25
|
+
if (numericFormatter) return numericFormatter(value)
|
|
26
|
+
if (prefix) return `${prefix}-[${value}]`
|
|
27
|
+
return `[${value}]`
|
|
31
28
|
}
|
|
32
29
|
|
|
33
30
|
return value ?? fallback
|
|
34
31
|
}
|
|
35
32
|
|
|
33
|
+
function getSizeClass(size: FontSize | undefined): string {
|
|
34
|
+
if (!size) return ''
|
|
35
|
+
return typeof size === 'number' ? `text-[${size}]` : `text-${size}`
|
|
36
|
+
}
|
|
37
|
+
|
|
36
38
|
export function useTypography(props: {
|
|
37
39
|
weight?: FontWeight
|
|
38
40
|
slant?: FontSlant
|
|
@@ -68,11 +70,7 @@ export function useTypography(props: {
|
|
|
68
70
|
fallback: 'tracking-normal',
|
|
69
71
|
}),
|
|
70
72
|
|
|
71
|
-
props.size
|
|
72
|
-
? typeof props.size === 'number'
|
|
73
|
-
? `text-[${props.size}]`
|
|
74
|
-
: `text-${props.size}`
|
|
75
|
-
: '',
|
|
73
|
+
getSizeClass(props.size),
|
|
76
74
|
|
|
77
75
|
props.align ? `text-${props.align}` : '',
|
|
78
76
|
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/* eslint-disable @typescript-eslint/consistent-type-imports */
|
|
2
1
|
export default defineAppConfig({
|
|
3
2
|
uiLayer: {
|
|
4
3
|
gradients: {
|
|
@@ -105,7 +104,7 @@ export default defineAppConfig({
|
|
|
105
104
|
})
|
|
106
105
|
|
|
107
106
|
declare module '@nuxt/schema' {
|
|
108
|
-
|
|
107
|
+
interface AppConfigInput {
|
|
109
108
|
uiLayer?: {
|
|
110
109
|
name?: string
|
|
111
110
|
gradients?: Record<string, import('./types/gradient').GradientConfig>
|