vue2-premium-bbl-editor 1.0.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/CHANGELOG.md +78 -0
- package/INSTALLATION.md +282 -0
- package/LICENSE +21 -0
- package/PUBLISH_GUIDE.md +101 -0
- package/PUBLISH_STEPS.md +60 -0
- package/README.md +412 -0
- package/dist/demo.html +10 -0
- package/dist/vue2-premium-bbl-editor.common.js +35865 -0
- package/dist/vue2-premium-bbl-editor.common.js.map +1 -0
- package/dist/vue2-premium-bbl-editor.css +1 -0
- package/dist/vue2-premium-bbl-editor.umd.js +35875 -0
- package/dist/vue2-premium-bbl-editor.umd.js.map +1 -0
- package/dist/vue2-premium-bbl-editor.umd.min.js +2 -0
- package/dist/vue2-premium-bbl-editor.umd.min.js.map +1 -0
- package/package.json +136 -0
- package/src/App.vue +57 -0
- package/src/README.md +276 -0
- package/src/assets/logo.png +0 -0
- package/src/components/EditorDemo.vue +397 -0
- package/src/components/Menus/BubbleMenu.vue +147 -0
- package/src/components/Menus/ImageBubbleMenu.vue +438 -0
- package/src/components/Menus/TableBubbleMenu.vue +996 -0
- package/src/components/Menus/VideoBubbleMenu.vue +438 -0
- package/src/components/Modals/ImageModal.vue +406 -0
- package/src/components/Modals/LinkModal.vue +255 -0
- package/src/components/Modals/TableModal.vue +352 -0
- package/src/components/Modals/VideoModal.vue +401 -0
- package/src/components/PremiumBblEditor.vue +1456 -0
- package/src/components/PremiumEditorDemo.vue +340 -0
- package/src/components/Toolbar/AlignmentDropdown.vue +221 -0
- package/src/components/Toolbar/BubbleMenuDropdown.vue +181 -0
- package/src/components/Toolbar/ColorPickerDropdown.vue +326 -0
- package/src/components/Toolbar/FontFamilyDropdown.vue +337 -0
- package/src/components/Toolbar/FontSizeDropdown.vue +265 -0
- package/src/components/Toolbar/HeadingDropdown.vue +275 -0
- package/src/components/Toolbar/HighlightPickerDropdown.vue +304 -0
- package/src/components/Toolbar/LineHeightDropdown.vue +252 -0
- package/src/components/Toolbar/ListDropdown.vue +219 -0
- package/src/components/Toolbar/TableDropdown.vue +296 -0
- package/src/components/Toolbar/ToolbarButton.vue +69 -0
- package/src/components/Toolbar/ToolbarGroup.vue +11 -0
- package/src/components/Toolbar/ToolbarMain.vue +470 -0
- package/src/components/index.js +9 -0
- package/src/components/svg/AboveColumn.vue +18 -0
- package/src/components/svg/AboveRow.vue +18 -0
- package/src/components/svg/AlignIcon.vue +33 -0
- package/src/components/svg/BelowColumn.vue +3 -0
- package/src/components/svg/BelowRow.vue +3 -0
- package/src/components/svg/BlockDisplay.vue +11 -0
- package/src/components/svg/BoxList.vue +3 -0
- package/src/components/svg/BulletList.vue +3 -0
- package/src/components/svg/CaptionBottom.vue +22 -0
- package/src/components/svg/CaptionTop.vue +22 -0
- package/src/components/svg/CellIcon.vue +19 -0
- package/src/components/svg/CenterAlign.vue +3 -0
- package/src/components/svg/ClearFormatting.vue +9 -0
- package/src/components/svg/Code.vue +12 -0
- package/src/components/svg/CodeBlock.vue +9 -0
- package/src/components/svg/ColorPalette.vue +15 -0
- package/src/components/svg/ColumnIcon.vue +19 -0
- package/src/components/svg/Delete.vue +14 -0
- package/src/components/svg/DeleteTable.vue +3 -0
- package/src/components/svg/Duplicate.vue +12 -0
- package/src/components/svg/ImageSvg.vue +3 -0
- package/src/components/svg/InlineDisplay.vue +11 -0
- package/src/components/svg/JustifyAlign.vue +3 -0
- package/src/components/svg/LeftAlign.vue +3 -0
- package/src/components/svg/Link.vue +3 -0
- package/src/components/svg/MergeCells.vue +23 -0
- package/src/components/svg/MoveDown.vue +11 -0
- package/src/components/svg/MoveLeft.vue +11 -0
- package/src/components/svg/MoveRight.vue +11 -0
- package/src/components/svg/MoveUp.vue +11 -0
- package/src/components/svg/Next.vue +3 -0
- package/src/components/svg/NoCaption.vue +22 -0
- package/src/components/svg/NumberList.vue +3 -0
- package/src/components/svg/Previous.vue +3 -0
- package/src/components/svg/Quote.vue +3 -0
- package/src/components/svg/RightAlign.vue +18 -0
- package/src/components/svg/RowIcon.vue +19 -0
- package/src/components/svg/SpacingLarge.vue +23 -0
- package/src/components/svg/SpacingMedium.vue +23 -0
- package/src/components/svg/SpacingSmall.vue +23 -0
- package/src/components/svg/SplitCell.vue +23 -0
- package/src/components/svg/Table.vue +3 -0
- package/src/components/svg/Video.vue +3 -0
- package/src/components/svg/index.js +43 -0
- package/src/composables/useEditor.js +393 -0
- package/src/extensions/CustomTableCell.js +21 -0
- package/src/extensions/CustomTableHeader.js +21 -0
- package/src/extensions/ResizableImage.js +476 -0
- package/src/extensions/ResizableVideo.js +521 -0
- package/src/index.js +76 -0
- package/src/main.js +8 -0
- package/src/styles/editor.css +324 -0
- package/src/styles/tables.css +117 -0
- package/src/styles/toolbar.css +187 -0
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to this project will be documented in this file.
|
|
4
|
+
|
|
5
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
|
+
|
|
8
|
+
## [1.0.0] - 2024-01-18
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
- Initial release of Vue 2 Premium BBL Editor
|
|
12
|
+
- Full Vue 2.6+ compatibility
|
|
13
|
+
- Production-ready rich text editor with Tiptap
|
|
14
|
+
- Comprehensive configuration system with 50+ props
|
|
15
|
+
- Multiple themes (default, minimal, dark)
|
|
16
|
+
- Advanced media handling (resizable images and videos)
|
|
17
|
+
- Interactive table system with cell controls
|
|
18
|
+
- Auto-save functionality
|
|
19
|
+
- Source code view toggle
|
|
20
|
+
- Upload handling with custom upload functions
|
|
21
|
+
- TypeScript definitions
|
|
22
|
+
- Comprehensive event system
|
|
23
|
+
- Bubble menus for contextual editing
|
|
24
|
+
- Toolbar customization
|
|
25
|
+
- Extension configuration system
|
|
26
|
+
- Content validation and limits
|
|
27
|
+
- Custom CSS class support
|
|
28
|
+
- Font family and size configuration
|
|
29
|
+
- Line height controls
|
|
30
|
+
- Text alignment options
|
|
31
|
+
- Color and highlight support
|
|
32
|
+
- Link management with modal
|
|
33
|
+
- Task lists with checkboxes
|
|
34
|
+
- Code blocks with syntax highlighting
|
|
35
|
+
- Blockquotes and horizontal rules
|
|
36
|
+
- Undo/redo functionality
|
|
37
|
+
- Placeholder support
|
|
38
|
+
- Spellcheck configuration
|
|
39
|
+
- Focus and blur handling
|
|
40
|
+
- Content format options (HTML/JSON)
|
|
41
|
+
- Responsive design
|
|
42
|
+
- Accessibility features
|
|
43
|
+
- Demo components and examples
|
|
44
|
+
- Comprehensive documentation
|
|
45
|
+
|
|
46
|
+
### Technical Features
|
|
47
|
+
- Vue plugin architecture
|
|
48
|
+
- Individual component exports
|
|
49
|
+
- Composable useEditor function
|
|
50
|
+
- Custom Tiptap extensions
|
|
51
|
+
- CSS-in-JS styling
|
|
52
|
+
- Build optimization for libraries
|
|
53
|
+
- External dependency management
|
|
54
|
+
- Tree-shaking support
|
|
55
|
+
- ES modules and CommonJS builds
|
|
56
|
+
- UMD build for CDN usage
|
|
57
|
+
|
|
58
|
+
### Documentation
|
|
59
|
+
- Complete README with usage examples
|
|
60
|
+
- TypeScript definitions
|
|
61
|
+
- API documentation
|
|
62
|
+
- Configuration guide
|
|
63
|
+
- Event handling examples
|
|
64
|
+
- Custom styling guide
|
|
65
|
+
- Upload handling examples
|
|
66
|
+
- Theme customization
|
|
67
|
+
- Extension configuration
|
|
68
|
+
- Troubleshooting guide
|
|
69
|
+
|
|
70
|
+
### Development
|
|
71
|
+
- Vue CLI build system
|
|
72
|
+
- Jest testing setup
|
|
73
|
+
- ESLint configuration
|
|
74
|
+
- Babel transpilation
|
|
75
|
+
- Development server
|
|
76
|
+
- Hot module replacement
|
|
77
|
+
- Production build optimization
|
|
78
|
+
- Library build configuration
|
package/INSTALLATION.md
ADDED
|
@@ -0,0 +1,282 @@
|
|
|
1
|
+
# Installation Guide
|
|
2
|
+
|
|
3
|
+
## Prerequisites
|
|
4
|
+
|
|
5
|
+
- Vue 2.6 or higher
|
|
6
|
+
- Node.js 12 or higher
|
|
7
|
+
- npm or yarn package manager
|
|
8
|
+
|
|
9
|
+
## Installation Methods
|
|
10
|
+
|
|
11
|
+
### 1. NPM Installation (Recommended)
|
|
12
|
+
|
|
13
|
+
```bash
|
|
14
|
+
npm install vue2-premium-bbl-editor
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
### 2. Yarn Installation
|
|
18
|
+
|
|
19
|
+
```bash
|
|
20
|
+
yarn add vue2-premium-bbl-editor
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
### 3. CDN Installation
|
|
24
|
+
|
|
25
|
+
```html
|
|
26
|
+
<!-- Vue 2 -->
|
|
27
|
+
<script src="https://unpkg.com/vue@2"></script>
|
|
28
|
+
|
|
29
|
+
<!-- Editor -->
|
|
30
|
+
<script src="https://unpkg.com/vue2-premium-bbl-editor"></script>
|
|
31
|
+
<link rel="stylesheet" href="https://unpkg.com/vue2-premium-bbl-editor/dist/vue2-premium-bbl-editor.css">
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
## Setup Methods
|
|
35
|
+
|
|
36
|
+
### Method 1: Global Registration (Recommended)
|
|
37
|
+
|
|
38
|
+
```javascript
|
|
39
|
+
// main.js
|
|
40
|
+
import Vue from 'vue'
|
|
41
|
+
import PremiumBblEditor from 'vue2-premium-bbl-editor'
|
|
42
|
+
|
|
43
|
+
// Register the plugin
|
|
44
|
+
Vue.use(PremiumBblEditor)
|
|
45
|
+
|
|
46
|
+
// Or with options
|
|
47
|
+
Vue.use(PremiumBblEditor, {
|
|
48
|
+
registerAllComponents: true // Registers all sub-components globally
|
|
49
|
+
})
|
|
50
|
+
|
|
51
|
+
new Vue({
|
|
52
|
+
render: h => h(App),
|
|
53
|
+
}).$mount('#app')
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
### Method 2: Component Registration
|
|
57
|
+
|
|
58
|
+
```javascript
|
|
59
|
+
// In your component
|
|
60
|
+
import { PremiumBblEditor } from 'vue2-premium-bbl-editor'
|
|
61
|
+
|
|
62
|
+
export default {
|
|
63
|
+
components: {
|
|
64
|
+
PremiumBblEditor
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
### Method 3: Individual Component Imports
|
|
70
|
+
|
|
71
|
+
```javascript
|
|
72
|
+
import {
|
|
73
|
+
PremiumBblEditor,
|
|
74
|
+
ToolbarMain,
|
|
75
|
+
ImageModal,
|
|
76
|
+
useEditor
|
|
77
|
+
} from 'vue2-premium-bbl-editor'
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
## Basic Usage
|
|
81
|
+
|
|
82
|
+
```vue
|
|
83
|
+
<template>
|
|
84
|
+
<div>
|
|
85
|
+
<PremiumBblEditor
|
|
86
|
+
v-model="content"
|
|
87
|
+
placeholder="Start writing..."
|
|
88
|
+
@input="handleInput"
|
|
89
|
+
/>
|
|
90
|
+
</div>
|
|
91
|
+
</template>
|
|
92
|
+
|
|
93
|
+
<script>
|
|
94
|
+
export default {
|
|
95
|
+
data() {
|
|
96
|
+
return {
|
|
97
|
+
content: '<p>Hello World!</p>'
|
|
98
|
+
}
|
|
99
|
+
},
|
|
100
|
+
methods: {
|
|
101
|
+
handleInput(content) {
|
|
102
|
+
console.log('Content updated:', content)
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
</script>
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
## TypeScript Setup
|
|
110
|
+
|
|
111
|
+
If you're using TypeScript, the package includes full type definitions:
|
|
112
|
+
|
|
113
|
+
```typescript
|
|
114
|
+
// types are automatically imported
|
|
115
|
+
import { PremiumBblEditor, ToolbarConfig } from 'vue2-premium-bbl-editor'
|
|
116
|
+
|
|
117
|
+
interface ComponentData {
|
|
118
|
+
content: string
|
|
119
|
+
config: ToolbarConfig
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
export default Vue.extend({
|
|
123
|
+
data(): ComponentData {
|
|
124
|
+
return {
|
|
125
|
+
content: '',
|
|
126
|
+
config: {
|
|
127
|
+
bold: true,
|
|
128
|
+
italic: true,
|
|
129
|
+
// ... other options
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
})
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
## CSS Import
|
|
137
|
+
|
|
138
|
+
The package includes CSS that needs to be imported:
|
|
139
|
+
|
|
140
|
+
### Method 1: Automatic (when using Vue plugin)
|
|
141
|
+
CSS is automatically imported when you use `Vue.use(PremiumBblEditor)`
|
|
142
|
+
|
|
143
|
+
### Method 2: Manual Import
|
|
144
|
+
```javascript
|
|
145
|
+
import 'vue2-premium-bbl-editor/dist/vue2-premium-bbl-editor.css'
|
|
146
|
+
```
|
|
147
|
+
|
|
148
|
+
### Method 3: CSS in HTML
|
|
149
|
+
```html
|
|
150
|
+
<link rel="stylesheet" href="https://unpkg.com/vue2-premium-bbl-editor/dist/vue2-premium-bbl-editor.css">
|
|
151
|
+
```
|
|
152
|
+
|
|
153
|
+
## Build Configuration
|
|
154
|
+
|
|
155
|
+
### Webpack Configuration
|
|
156
|
+
|
|
157
|
+
If you're using a custom webpack setup, you may need to configure it to handle the package:
|
|
158
|
+
|
|
159
|
+
```javascript
|
|
160
|
+
// webpack.config.js
|
|
161
|
+
module.exports = {
|
|
162
|
+
resolve: {
|
|
163
|
+
alias: {
|
|
164
|
+
'vue$': 'vue/dist/vue.esm.js'
|
|
165
|
+
}
|
|
166
|
+
},
|
|
167
|
+
module: {
|
|
168
|
+
rules: [
|
|
169
|
+
{
|
|
170
|
+
test: /\.vue$/,
|
|
171
|
+
loader: 'vue-loader'
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
test: /\.css$/,
|
|
175
|
+
use: ['style-loader', 'css-loader']
|
|
176
|
+
}
|
|
177
|
+
]
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
```
|
|
181
|
+
|
|
182
|
+
### Vue CLI Configuration
|
|
183
|
+
|
|
184
|
+
For Vue CLI projects, add this to your `vue.config.js`:
|
|
185
|
+
|
|
186
|
+
```javascript
|
|
187
|
+
// vue.config.js
|
|
188
|
+
module.exports = {
|
|
189
|
+
transpileDependencies: [
|
|
190
|
+
'vue2-premium-bbl-editor'
|
|
191
|
+
]
|
|
192
|
+
}
|
|
193
|
+
```
|
|
194
|
+
|
|
195
|
+
## Nuxt.js Setup
|
|
196
|
+
|
|
197
|
+
For Nuxt.js applications:
|
|
198
|
+
|
|
199
|
+
```javascript
|
|
200
|
+
// nuxt.config.js
|
|
201
|
+
export default {
|
|
202
|
+
plugins: [
|
|
203
|
+
{ src: '~/plugins/tiptap-editor.js', mode: 'client' }
|
|
204
|
+
],
|
|
205
|
+
css: [
|
|
206
|
+
'vue2-premium-bbl-editor/dist/vue2-premium-bbl-editor.css'
|
|
207
|
+
]
|
|
208
|
+
}
|
|
209
|
+
```
|
|
210
|
+
|
|
211
|
+
```javascript
|
|
212
|
+
// plugins/tiptap-editor.js
|
|
213
|
+
import Vue from 'vue'
|
|
214
|
+
import PremiumBblEditor from 'vue2-premium-bbl-editor'
|
|
215
|
+
|
|
216
|
+
Vue.use(PremiumBblEditor)
|
|
217
|
+
```
|
|
218
|
+
|
|
219
|
+
## Troubleshooting
|
|
220
|
+
|
|
221
|
+
### Common Issues
|
|
222
|
+
|
|
223
|
+
1. **"Cannot resolve module" error**
|
|
224
|
+
- Make sure you've installed the package: `npm install vue2-premium-bbl-editor`
|
|
225
|
+
- Check that your Node.js version is 12 or higher
|
|
226
|
+
|
|
227
|
+
2. **CSS not loading**
|
|
228
|
+
- Import the CSS manually: `import 'vue2-premium-bbl-editor/dist/vue2-premium-bbl-editor.css'`
|
|
229
|
+
- Or use the CDN link in your HTML
|
|
230
|
+
|
|
231
|
+
3. **TypeScript errors**
|
|
232
|
+
- Make sure you have the latest version of the package
|
|
233
|
+
- Check that your `tsconfig.json` includes the package in `types`
|
|
234
|
+
|
|
235
|
+
4. **Build errors with Vue CLI**
|
|
236
|
+
- Add the package to `transpileDependencies` in `vue.config.js`
|
|
237
|
+
|
|
238
|
+
5. **SSR issues with Nuxt.js**
|
|
239
|
+
- Use client-side only plugin: `{ src: '~/plugins/tiptap-editor.js', mode: 'client' }`
|
|
240
|
+
|
|
241
|
+
### Browser Compatibility
|
|
242
|
+
|
|
243
|
+
The editor supports:
|
|
244
|
+
- Chrome 60+
|
|
245
|
+
- Firefox 55+
|
|
246
|
+
- Safari 11+
|
|
247
|
+
- Edge 79+
|
|
248
|
+
|
|
249
|
+
For older browsers, you may need additional polyfills.
|
|
250
|
+
|
|
251
|
+
### Performance Optimization
|
|
252
|
+
|
|
253
|
+
For better performance in production:
|
|
254
|
+
|
|
255
|
+
1. **Tree Shaking**: Import only the components you need
|
|
256
|
+
2. **Code Splitting**: Use dynamic imports for the editor
|
|
257
|
+
3. **CSS Optimization**: Use PurgeCSS to remove unused styles
|
|
258
|
+
|
|
259
|
+
```javascript
|
|
260
|
+
// Dynamic import example
|
|
261
|
+
const PremiumBblEditor = () => import('vue2-premium-bbl-editor')
|
|
262
|
+
|
|
263
|
+
export default {
|
|
264
|
+
components: {
|
|
265
|
+
PremiumBblEditor
|
|
266
|
+
}
|
|
267
|
+
}
|
|
268
|
+
```
|
|
269
|
+
|
|
270
|
+
## Next Steps
|
|
271
|
+
|
|
272
|
+
- Check out the [README.md](README.md) for full API documentation
|
|
273
|
+
- See [examples/](examples/) for usage examples
|
|
274
|
+
- Read the [CHANGELOG.md](CHANGELOG.md) for version history
|
|
275
|
+
|
|
276
|
+
## Support
|
|
277
|
+
|
|
278
|
+
If you encounter any issues during installation:
|
|
279
|
+
|
|
280
|
+
1. Check the [GitHub Issues](https://github.com/yourusername/vue2-premium-bbl-editor/issues)
|
|
281
|
+
2. Make sure you're using compatible versions of Vue and Node.js
|
|
282
|
+
3. Try clearing your node_modules and reinstalling: `rm -rf node_modules package-lock.json && npm install`
|
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2024 Vue 2 Premium Tiptap Editor
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/PUBLISH_GUIDE.md
ADDED
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
# Publishing Guide for Vue 2 Premium BBL Editor
|
|
2
|
+
|
|
3
|
+
## 🚀 Complete Publishing Steps
|
|
4
|
+
|
|
5
|
+
### Step 1: ✅ Build Library (COMPLETED)
|
|
6
|
+
```bash
|
|
7
|
+
npm run build:lib
|
|
8
|
+
```
|
|
9
|
+
|
|
10
|
+
### Step 2: ✅ Git Commit (COMPLETED)
|
|
11
|
+
```bash
|
|
12
|
+
git add .
|
|
13
|
+
git commit -m "feat: Initial release of Vue 2 Premium BBL Editor v1.0.0"
|
|
14
|
+
git tag -a v1.0.0 -m "Release version 1.0.0"
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
### Step 3: 📡 Push to GitHub
|
|
18
|
+
|
|
19
|
+
1. **Create GitHub Repository:**
|
|
20
|
+
- Go to https://github.com/new
|
|
21
|
+
- Repository name: `vue2-premium-bbl-editor`
|
|
22
|
+
- Description: "A production-ready, fully configurable rich text editor for Vue 2.6 built with Tiptap"
|
|
23
|
+
- Make it Public
|
|
24
|
+
- Don't initialize with README (we already have one)
|
|
25
|
+
|
|
26
|
+
2. **Add Remote and Push:**
|
|
27
|
+
```bash
|
|
28
|
+
# Replace 'yourusername' with your actual GitHub username
|
|
29
|
+
git remote add origin https://github.com/yourusername/vue2-premium-bbl-editor.git
|
|
30
|
+
|
|
31
|
+
# Push code and tags
|
|
32
|
+
git push -u origin main
|
|
33
|
+
git push origin --tags
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
### Step 4: 📦 Publish to NPM
|
|
37
|
+
|
|
38
|
+
1. **Login to NPM:**
|
|
39
|
+
```bash
|
|
40
|
+
npm login
|
|
41
|
+
```
|
|
42
|
+
Enter your NPM credentials when prompted.
|
|
43
|
+
|
|
44
|
+
2. **Verify Package:**
|
|
45
|
+
```bash
|
|
46
|
+
npm pack --dry-run
|
|
47
|
+
```
|
|
48
|
+
This shows what files will be included in the package.
|
|
49
|
+
|
|
50
|
+
3. **Publish Package:**
|
|
51
|
+
```bash
|
|
52
|
+
npm publish
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
### Step 5: 🔧 Post-Publication Setup
|
|
56
|
+
|
|
57
|
+
1. **Update GitHub Repository:**
|
|
58
|
+
- Add repository description
|
|
59
|
+
- Add topics/tags: `vue`, `vue2`, `editor`, `tiptap`, `rich-text`, `wysiwyg`
|
|
60
|
+
- Enable GitHub Pages for documentation (optional)
|
|
61
|
+
|
|
62
|
+
2. **Create GitHub Release:**
|
|
63
|
+
- Go to your repository → Releases → Create a new release
|
|
64
|
+
- Tag: `v1.0.0`
|
|
65
|
+
- Title: `Vue 2 Premium BBL Editor v1.0.0`
|
|
66
|
+
- Description: Copy from CHANGELOG.md
|
|
67
|
+
|
|
68
|
+
## 📋 Pre-Publication Checklist
|
|
69
|
+
|
|
70
|
+
- ✅ Package built successfully
|
|
71
|
+
- ✅ All tests passing
|
|
72
|
+
- ✅ ESLint errors fixed
|
|
73
|
+
- ✅ Documentation complete
|
|
74
|
+
- ✅ Version tagged
|
|
75
|
+
- ✅ Git repository ready
|
|
76
|
+
|
|
77
|
+
## 🎯 Installation Instructions for Users
|
|
78
|
+
|
|
79
|
+
Once published, users can install with:
|
|
80
|
+
|
|
81
|
+
```bash
|
|
82
|
+
npm install vue2-premium-bbl-editor
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
## 🔄 Future Updates
|
|
86
|
+
|
|
87
|
+
For future versions:
|
|
88
|
+
|
|
89
|
+
1. Update version in `package.json`
|
|
90
|
+
2. Update `CHANGELOG.md`
|
|
91
|
+
3. Build: `npm run build:lib`
|
|
92
|
+
4. Commit: `git commit -m "feat: version x.x.x"`
|
|
93
|
+
5. Tag: `git tag -a vx.x.x -m "Release version x.x.x"`
|
|
94
|
+
6. Push: `git push && git push --tags`
|
|
95
|
+
7. Publish: `npm publish`
|
|
96
|
+
|
|
97
|
+
## 📞 Support
|
|
98
|
+
|
|
99
|
+
- Repository: https://github.com/yourusername/vue2-premium-bbl-editor
|
|
100
|
+
- NPM Package: https://www.npmjs.com/package/vue2-premium-bbl-editor
|
|
101
|
+
- Issues: https://github.com/yourusername/vue2-premium-bbl-editor/issues
|
package/PUBLISH_STEPS.md
ADDED
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
# Final Publishing Steps
|
|
2
|
+
|
|
3
|
+
## Current Status: ✅ Almost Complete!
|
|
4
|
+
|
|
5
|
+
- ✅ GitHub repository: https://github.com/Mahadi74/vue2-premium-bbl-editor
|
|
6
|
+
- ✅ Code pushed successfully
|
|
7
|
+
- ✅ NPM account logged in
|
|
8
|
+
- ⚠️ Need to complete 2FA setup
|
|
9
|
+
|
|
10
|
+
## Next Steps:
|
|
11
|
+
|
|
12
|
+
### 1. Set up 2FA on NPM (Required)
|
|
13
|
+
1. Go to: https://www.npmjs.com/settings/meheduhasan60/tfa
|
|
14
|
+
2. Click "Add Two-Factor Authentication"
|
|
15
|
+
3. Choose "Authenticator App"
|
|
16
|
+
4. Use Google Authenticator, Authy, or similar app
|
|
17
|
+
5. Scan QR code and enter verification code
|
|
18
|
+
6. Save backup codes in a safe place
|
|
19
|
+
|
|
20
|
+
### 2. Publish Package
|
|
21
|
+
After 2FA is set up, run:
|
|
22
|
+
```bash
|
|
23
|
+
npm publish
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
You'll be prompted for your 2FA code during publishing.
|
|
27
|
+
|
|
28
|
+
### 3. Verify Publication
|
|
29
|
+
```bash
|
|
30
|
+
npm view vue2-premium-bbl-editor
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
## Alternative: Create Access Token
|
|
34
|
+
|
|
35
|
+
If you prefer using an access token:
|
|
36
|
+
|
|
37
|
+
1. Go to: https://www.npmjs.com/settings/meheduhasan60/tokens
|
|
38
|
+
2. Click "Generate New Token"
|
|
39
|
+
3. Choose "Granular Access Token"
|
|
40
|
+
4. Set permissions for publishing
|
|
41
|
+
5. Copy the token
|
|
42
|
+
6. Use: `npm config set //registry.npmjs.org/:_authToken YOUR_TOKEN`
|
|
43
|
+
|
|
44
|
+
## After Publishing
|
|
45
|
+
|
|
46
|
+
Your package will be available at:
|
|
47
|
+
- NPM: https://www.npmjs.com/package/vue2-premium-bbl-editor
|
|
48
|
+
- GitHub: https://github.com/Mahadi74/vue2-premium-bbl-editor
|
|
49
|
+
|
|
50
|
+
Users can install with:
|
|
51
|
+
```bash
|
|
52
|
+
npm install vue2-premium-bbl-editor
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
## Package Info
|
|
56
|
+
- Name: vue2-premium-bbl-editor
|
|
57
|
+
- Version: 1.0.0
|
|
58
|
+
- Size: 1.8 MB (124 KB gzipped)
|
|
59
|
+
- Files: 96 files included
|
|
60
|
+
- Built: ✅ Ready for distribution
|