-
Notifications
You must be signed in to change notification settings - Fork 474
Migrate all toolbar components to standalone and use the new syntax #32257
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
Changes from 1 commit
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
b26549f
refactor(modules): Replace DotToolbarModule with DotToolbarComponent …
nicobytes 75fa8e9
refactor(dot-dropdown): Enhance dropdown component with signals and c…
nicobytes dc50347
Merge branch '32256-new-angular-syntax-in-dottoolbarcomponent' of git…
nicobytes 3c53e33
refactor(dot-dropdown): Update dropdown component to utilize signals …
nicobytes 6832eed
chore(dependencies): Update ng-mocks to version 14.13.5 for improved …
nicobytes cef84ac
refactor(dot-crumbtrail): Remove DotCrumbtrailModule as part of compo…
nicobytes 1247a9d
refactor(components): Update templates to utilize new Angular syntax …
nicobytes f796e66
Merge branch 'main' into 32256-new-angular-syntax-in-dottoolbarcomponent
nicobytes 5c7f066
refactor(dot-notifications): Reorganize imports for improved clarity …
nicobytes 52dda86
Merge branch '32256-new-angular-syntax-in-dottoolbarcomponent' of git…
nicobytes f83e2cf
refactor(dot-notifications): Update button import and fix template sy…
nicobytes 8e9f58a
refactor(dot-notifications): Update button import and fix template sy…
nicobytes faa14e7
Update core-web/apps/dotcms-ui/src/app/view/components/_common/dot-dr…
nicobytes af482c0
refactor(components): Update templates to utilize new Angular syntax …
nicobytes acd9298
chore(dependencies): downgrade ng-mocks to version 14.12.1 to resolve…
nicobytes b8c551b
sync with master
nicobytes ad55a5e
chore(dotcms-ui): Refactor DotToolbar and SharedModule components
nicobytes 9704f2a
Merge branch 'main' into 32256-new-angular-syntax-in-dottoolbarcomponent
nicobytes b58834f
refactor(dotcms-ui): Replace DotDropdownComponent with DotDropdownMod…
nicobytes File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
refactor(dot-dropdown): Enhance dropdown component with signals and c…
…omputed properties for improved state management
- Loading branch information
commit 75fa8e9e09ae9b592eebfc4b4a5fb0ed11f8bb8c
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
import { DatePipe, LowerCasePipe, NgClass } from '@angular/common'; | ||
import { CommonModule } from '@angular/common'; | ||
import { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Could you move this component to the UI lib? |
||
Component, | ||
EventEmitter, | ||
|
@@ -7,9 +7,9 @@ import { | |
OnInit, | ||
Output, | ||
Signal, | ||
ViewChild, | ||
inject, | ||
signal | ||
signal, | ||
viewChild | ||
} from '@angular/core'; | ||
import { takeUntilDestroyed } from '@angular/core/rxjs-interop'; | ||
|
||
|
@@ -30,14 +30,14 @@ import { DotMessagePipe } from '@dotcms/ui'; | |
templateUrl: './dot-toolbar-announcements.component.html', | ||
styleUrls: ['./dot-toolbar-announcements.component.scss'], | ||
standalone: true, | ||
imports: [NgClass, DotMessagePipe, OverlayPanelModule, LowerCasePipe, DatePipe], | ||
imports: [CommonModule, DotMessagePipe, OverlayPanelModule], | ||
providers: [AnnouncementsStore] | ||
}) | ||
export class DotToolbarAnnouncementsComponent implements OnInit, OnChanges { | ||
announcementsStore = inject(AnnouncementsStore); | ||
dotMessageService = inject(DotMessageService); | ||
siteService = inject(SiteService); | ||
@ViewChild('toolbarAnnouncements', { static: true }) toolbarAnnouncements: OverlayPanel; | ||
$toolbarAnnouncements = viewChild.required<OverlayPanel>('toolbarAnnouncements'); | ||
@Output() hideMenu = new EventEmitter(); | ||
|
||
@Input() showUnreadAnnouncement: boolean; | ||
|
@@ -85,7 +85,7 @@ export class DotToolbarAnnouncementsComponent implements OnInit, OnChanges { | |
*/ | ||
toggleDialog(event): void { | ||
this.showMask.update((value) => !value); | ||
this.toolbarAnnouncements.toggle(event); | ||
this.$toolbarAnnouncements().toggle(event); | ||
} | ||
|
||
/** | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not use dropdown from primeNg instead of
DotDropdownComponent