v-code-diff 1.8.0 → 1.9.0
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/README.md +11 -2
- package/dist/v2/index.cjs.js +16 -14
- package/dist/v2/index.es.js +687 -658
- package/dist/v2/index.umd.js +15 -13
- package/dist/v2.7/index.cjs.js +18 -16
- package/dist/v2.7/index.es.js +986 -960
- package/dist/v2.7/index.umd.js +18 -16
- package/dist/v3/index.cjs.js +18 -16
- package/dist/v3/index.es.js +1298 -1272
- package/dist/v3/index.umd.js +18 -16
- package/package.json +16 -14
- package/scripts/{postinstall.js → postinstall.cjs} +1 -2
- package/scripts/{utils.js → utils.cjs} +0 -2
- package/src/CodeDiff.vue +9 -8
- package/src/style.scss +7 -1
- package/src/types.ts +2 -0
- package/src/utils.ts +44 -13
- package/types/index.d.ts +5 -4
package/README.md
CHANGED
|
@@ -48,7 +48,7 @@ yarn add v-code-diff
|
|
|
48
48
|
pnpm add v-code-diff
|
|
49
49
|
```
|
|
50
50
|
|
|
51
|
-
Vue2 developers need install composition-api
|
|
51
|
+
Vue2.6 developers need install composition-api
|
|
52
52
|
|
|
53
53
|
```shell
|
|
54
54
|
pnpm add @vue/composition-api
|
|
@@ -123,7 +123,10 @@ Not recommended, but the relevant capabilities are retained to facilitate migrat
|
|
|
123
123
|
| maxHeight | Maximum height of component, for example: 300px | string | - | undefined |
|
|
124
124
|
| filename | Filename | string | - | undefined |
|
|
125
125
|
| newFilename | New filename | string | - | undefined |
|
|
126
|
-
|
|
|
126
|
+
| hideHeader | Hide header bar | boolean | - | false |
|
|
127
|
+
| hideStat | Hide statistical part in the header bar | boolean | - | false |
|
|
128
|
+
| theme | Add dark mode | ThemeType | light , dark | light |
|
|
129
|
+
| ignoreMatchingLines | Give a pattern to ignore matching lines eg: '(time\|token)' | string | - | undefined |
|
|
127
130
|
|
|
128
131
|
## Events
|
|
129
132
|
|
|
@@ -131,6 +134,12 @@ Not recommended, but the relevant capabilities are retained to facilitate migrat
|
|
|
131
134
|
| ---- | --------------------------- | ------------------------------------------------------------------------------- |
|
|
132
135
|
| diff | triggers when diff finished | (result: {stat: { isChanged: boolean, addNum: number, delNum: number}}) => void |
|
|
133
136
|
|
|
137
|
+
## Slot
|
|
138
|
+
|
|
139
|
+
| Name | Description |
|
|
140
|
+
| ---- | ----------------------------------------------------------- |
|
|
141
|
+
| stat | Custom statistical content, The scope parameter is { stat } |
|
|
142
|
+
|
|
134
143
|
## Extend languages
|
|
135
144
|
|
|
136
145
|
In order to reduce the size of the packaged file, the system only supports the following commonly used languages by
|