Skip to content

Commit 1b2de8e

Browse files
authored
docs(fluent-editor): fix text exceeding problem caused by too long content in the fluent-editor component demo (#2711)
* docs(fluent-editor): fixed text exceeding problem caused by too long content in the fluent-editor component demo * docs(fluent-editor): remove useless demo code
1 parent b1e5e77 commit 1b2de8e

12 files changed

+40
-60
lines changed

examples/sites/demos/pc/app/fluent-editor/basic-usage-composition-api.vue

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<template>
2-
<div>
3-
<tiny-fluent-editor v-model="content"></tiny-fluent-editor>
2+
<tiny-fluent-editor v-model="content"></tiny-fluent-editor>
3+
<div class="fluent-editor-demo__basic-usage__content">
44
内容:<br />
55
{{ content }}
66
</div>
@@ -12,3 +12,11 @@ import { TinyFluentEditor } from '@opentiny/vue'
1212
1313
const content = ref('{"ops":[{"insert":"Hello "},{"attributes":{"bold":true},"insert":"FluentEditor"},{"insert":"!"}]}')
1414
</script>
15+
16+
<style scoped>
17+
.fluent-editor-demo__basic-usage__content {
18+
margin: 16px 0;
19+
line-height: 1.5;
20+
word-break: break-word;
21+
}
22+
</style>

examples/sites/demos/pc/app/fluent-editor/basic-usage.vue

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<template>
2-
<div>
3-
<tiny-fluent-editor v-model="content"></tiny-fluent-editor>
2+
<tiny-fluent-editor v-model="content"></tiny-fluent-editor>
3+
<div class="fluent-editor-demo__basic-usage__content">
44
内容:<br />
55
{{ content }}
66
</div>
@@ -20,3 +20,11 @@ export default {
2020
}
2121
}
2222
</script>
23+
24+
<style scoped>
25+
.fluent-editor-demo__basic-usage__content {
26+
margin: 16px 0;
27+
line-height: 1.5;
28+
word-break: break-word;
29+
}
30+
</style>

examples/sites/demos/pc/app/fluent-editor/before-editor-init-composition-api.vue

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,10 @@
11
<template>
2-
<div>
3-
<tiny-fluent-editor
4-
ref="fluentEditorRef"
5-
v-model="content"
6-
:before-editor-init="beforeEditorInit"
7-
:options="editorOptions"
8-
></tiny-fluent-editor>
9-
内容:<br />
10-
{{ content }}
11-
</div>
2+
<tiny-fluent-editor
3+
ref="fluentEditorRef"
4+
v-model="content"
5+
:before-editor-init="beforeEditorInit"
6+
:options="editorOptions"
7+
></tiny-fluent-editor>
128
</template>
139

1410
<script setup>

examples/sites/demos/pc/app/fluent-editor/before-editor-init.vue

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,10 @@
11
<template>
2-
<div>
3-
<tiny-fluent-editor
4-
ref="fluentEditorRef"
5-
v-model="content"
6-
:before-editor-init="beforeEditorInit"
7-
:options="editorOptions"
8-
></tiny-fluent-editor>
9-
内容:<br />
10-
{{ content }}
11-
</div>
2+
<tiny-fluent-editor
3+
ref="fluentEditorRef"
4+
v-model="content"
5+
:before-editor-init="beforeEditorInit"
6+
:options="editorOptions"
7+
></tiny-fluent-editor>
128
</template>
139

1410
<script>

examples/sites/demos/pc/app/fluent-editor/data-switch-composition-api.vue

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
<template>
2-
<div>
3-
<tiny-fluent-editor v-model="value" :data-type="false" :data-upgrade="false"></tiny-fluent-editor>
4-
内容:<br />
5-
{{ value }}
6-
</div>
2+
<tiny-fluent-editor v-model="value" :data-type="false" :data-upgrade="false"></tiny-fluent-editor>
73
</template>
84

95
<script setup>

examples/sites/demos/pc/app/fluent-editor/data-switch.vue

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
<template>
2-
<div>
3-
<tiny-fluent-editor v-model="value" :data-type="false" :data-upgrade="false"></tiny-fluent-editor>
4-
内容:<br />
5-
{{ value }}
6-
</div>
2+
<tiny-fluent-editor v-model="value" :data-type="false" :data-upgrade="false"></tiny-fluent-editor>
73
</template>
84

95
<script>

examples/sites/demos/pc/app/fluent-editor/disabled-composition-api.vue

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
<template>
2-
<div>
3-
<tiny-fluent-editor v-model="content" disabled></tiny-fluent-editor>
4-
</div>
2+
<tiny-fluent-editor v-model="content" disabled></tiny-fluent-editor>
53
</template>
64

75
<script setup>

examples/sites/demos/pc/app/fluent-editor/disabled.vue

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
<template>
2-
<div>
3-
<tiny-fluent-editor v-model="content" disabled></tiny-fluent-editor>
4-
</div>
2+
<tiny-fluent-editor v-model="content" disabled></tiny-fluent-editor>
53
</template>
64

75
<script>

examples/sites/demos/pc/app/fluent-editor/image-upload-composition-api.vue

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
<template>
2-
<div>
3-
<tiny-fluent-editor v-model="content" :image-upload="imageUpload"></tiny-fluent-editor>
4-
内容:<br />
5-
{{ content }}
6-
</div>
2+
<tiny-fluent-editor v-model="content" :image-upload="imageUpload"></tiny-fluent-editor>
73
</template>
84

95
<script setup>

examples/sites/demos/pc/app/fluent-editor/image-upload.vue

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
<template>
2-
<div>
3-
<tiny-fluent-editor v-model="content" :image-upload="imageUpload"></tiny-fluent-editor>
4-
内容:<br />
5-
{{ content }}
6-
</div>
2+
<tiny-fluent-editor v-model="content" :image-upload="imageUpload"></tiny-fluent-editor>
73
</template>
84

95
<script>

examples/sites/demos/pc/app/fluent-editor/options-composition-api.vue

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
<template>
2-
<div>
3-
<tiny-fluent-editor v-model="content" :options="options"></tiny-fluent-editor>
4-
内容:<br />
5-
{{ content }}
6-
</div>
2+
<tiny-fluent-editor v-model="content" :options="options"></tiny-fluent-editor>
73
</template>
84

95
<script setup>

examples/sites/demos/pc/app/fluent-editor/options.vue

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
<template>
2-
<div>
3-
<tiny-fluent-editor v-model="content" :options="options"></tiny-fluent-editor>
4-
内容:<br />
5-
{{ content }}
6-
</div>
2+
<tiny-fluent-editor v-model="content" :options="options"></tiny-fluent-editor>
73
</template>
84

95
<script>

0 commit comments

Comments
 (0)