fix component preview styles
This commit is contained in:
parent
d72438f0a7
commit
0d32a7ddac
7 changed files with 240 additions and 215 deletions
|
|
@ -410,7 +410,7 @@ const AppearanceTab = {
|
|||
this.compilationCache[key] = theme3
|
||||
}
|
||||
|
||||
const styleEl = document.getElementById('theme-holder')
|
||||
const styleEl = document.getElementById('theme-preview-holder')
|
||||
const styleSheet = styleEl.sheet
|
||||
styleSheet.insertRule([
|
||||
'#theme-preview-',
|
||||
|
|
|
|||
|
|
@ -729,7 +729,7 @@ export default {
|
|||
// Apart from "hover" we can't really show how component looks like in
|
||||
// certain states, so we have to fake them.
|
||||
const simulatePseudoSelectors = (css, prefix) => css
|
||||
.replace(prefix, '.component-preview .preview-block')
|
||||
.replace(prefix, '.preview-block')
|
||||
.replace(':active', '.preview-active')
|
||||
.replace(':hover', '.preview-hover')
|
||||
.replace(':active', '.preview-active')
|
||||
|
|
|
|||
|
|
@ -155,12 +155,6 @@
|
|||
</ul>
|
||||
</div>
|
||||
<div class="preview-container">
|
||||
<!-- eslint-disable vue/no-v-html vue/no-v-text-v-html-on-component -->
|
||||
<component
|
||||
:is="'style'"
|
||||
v-html="previewCss"
|
||||
/>
|
||||
<!-- eslint-enable vue/no-v-html vue/no-v-text-v-html-on-component -->
|
||||
<ComponentPreview
|
||||
class="component-preview"
|
||||
:show-text="componentHas('Text')"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue