Skip to content

Commit

Permalink
feat: use unique component prefix
Browse files Browse the repository at this point in the history
Closes #12
  • Loading branch information
iklimisdev authored and bampakoa committed May 6, 2022
1 parent 51b5cf9 commit e498629
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions projects/demo-editor/src/app/app.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
<label for="newsletter">Newsletter</label>
</div>
<div class="editor">
<lib-newsletter-editor *ngIf="editorMode === 'newsletter'" [template]="template" [placeholders]="placeholders"></lib-newsletter-editor>
<lib-webpage-editor *ngIf="editorMode === 'webpage'" [template]="template"></lib-webpage-editor>
<ngx-grapes-newsletter-editor *ngIf="editorMode === 'newsletter'" [template]="template" [placeholders]="placeholders"></ngx-grapes-newsletter-editor>
<ngx-grapes-webpage-editor *ngIf="editorMode === 'webpage'" [template]="template"></ngx-grapes-webpage-editor>
</div>
2 changes: 1 addition & 1 deletion projects/ngx-grapesjs/.eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"error",
{
"type": "element",
"prefix": "lib",
"prefix": "ngx-grapes",
"style": "kebab-case"
}
],
Expand Down
4 changes: 2 additions & 2 deletions projects/ngx-grapesjs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,13 @@ The previous command will ask you which editor mode you want to use and it will
For webpage mode:

```html
<lib-webpage-editor></lib-webpage-editor>
<ngx-grapes-webpage-editor></ngx-grapes-webpage-editor>
```

For newsletter mode:

```html
<lib-newsletter-editor></lib-newsletter-editor>
<ngx-grapes-newsletter-editor></ngx-grapes-newsletter-editor>
```

Both editors support passing the following input properties:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { NgxNewsletterEditorService } from './ngx-newsletter-editor.service';
import { Placeholder } from './placeholder.model';

@Component({
selector: 'lib-newsletter-editor',
selector: 'ngx-grapes-newsletter-editor',
template: '<div id="gjs"></div>'
})
export class NgxNewsletterEditorComponent extends NgxEditorComponent implements OnInit {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { NgxEditorComponent } from '../editor.component';
import { Config } from '../editor.model';

@Component({
selector: 'lib-webpage-editor',
selector: 'ngx-grapes-webpage-editor',
template: '<div id="gjs"></div>'
})

Expand Down

0 comments on commit e498629

Please sign in to comment.