From 21d6781acc794391ae1c01b1ca095aa30f4be1d4 Mon Sep 17 00:00:00 2001 From: "oe.sonnh" Date: Tue, 5 Mar 2024 21:00:28 +0700 Subject: [PATCH] Fix: styles for docs frame preview --- docs/.vitepress/config.mts | 4 ++-- docs/.vitepress/theme/components/Examples.vue | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/.vitepress/config.mts b/docs/.vitepress/config.mts index 3294b891..3ade40bb 100644 --- a/docs/.vitepress/config.mts +++ b/docs/.vitepress/config.mts @@ -1,4 +1,4 @@ -import { defineConfig, withBase } from 'vitepress'; +import { defineConfig } from 'vitepress'; import { fileURLToPath } from 'url'; import { replaceCodePlugin } from 'vite-plugin-replace'; import svgLoader from 'vite-svg-loader'; @@ -20,7 +20,7 @@ export default defineConfig({ titleTemplate: ":title — Shopify Polaris Vue by ownego", description: "Shopify Polaris for VueJS 3", head: [ - ['link', { rel: 'icon', href: withBase('/assets/images/favicon.ico') }], + ['link', { rel: 'icon', href: '/polaris-vue/assets/images/favicon.ico' }], ['link', { rel: 'preconnect', href: 'https://cdn.shopify.com/' }], ['link', { rel: 'stylesheet', href: 'https://cdn.shopify.com/static/fonts/inter/inter.css', id: 'inter-font-link' }], ], diff --git a/docs/.vitepress/theme/components/Examples.vue b/docs/.vitepress/theme/components/Examples.vue index 24db337d..967a79e8 100644 --- a/docs/.vitepress/theme/components/Examples.vue +++ b/docs/.vitepress/theme/components/Examples.vue @@ -13,7 +13,7 @@ v-html="md.render(examples[selectedExampleIndex].description)", ) //- Iframe to show example - .preview-wrapper(:style="{ height: `${frameHeight}px` }") + .frame-wrapper(:style="{ height: `${frameHeight}px` }") iframe.preview-frame( ref="iframeRef", :src="withBase(`/preview/${component}-${selectedFile}`)", @@ -165,7 +165,7 @@ if (example) { } } -.preview-wrapper { +.frame-wrapper { position: relative; width: 100%; background-color: #f1f1f1;