@gipisistemas/ngx-core 1.0.21 → 1.0.23

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.
@@ -8,6 +8,7 @@
8
8
  $white-100: utils.get-color($theme, white, 100);
9
9
  $secondary-50: utils.get-color($theme, secondary, 50);
10
10
  $secondary-100: utils.get-color($theme, secondary, 100);
11
+ $secondary-600: utils.get-color($theme, secondary, 600);
11
12
  $black-300: utils.get-color($theme, black, 300);
12
13
 
13
14
  .g-expansion-panel {
@@ -74,6 +75,16 @@
74
75
  font-weight: 700 !important;
75
76
  line-height: 2rem !important;
76
77
  letter-spacing: normal !important;
78
+
79
+ .g-expansion-panel-required {
80
+ margin-left: 0.8rem !important;
81
+ padding: 0.2rem 0.8rem !important;
82
+ font-size: 1.2rem !important;
83
+ line-height: 1.6rem !important;
84
+ color: $secondary-600 !important;
85
+ background: $secondary-100 !important;
86
+ border-radius: 9999px !important;
87
+ }
77
88
  }
78
89
 
79
90
  .g-expansion-panel-icon {
@@ -4458,7 +4458,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
4458
4458
  * const userId = useRouteParam('id');
4459
4459
  * ```
4460
4460
  */
4461
- function useRouteParams(paramName) {
4461
+ function useRouteParam(paramName) {
4462
4462
  const route = inject(ActivatedRoute);
4463
4463
  return toSignal(route.paramMap.pipe(map((pm) => pm.get(paramName))), {
4464
4464
  initialValue: route.snapshot.paramMap.get(paramName),
@@ -4491,6 +4491,7 @@ class BaseFormComponent extends BaseComponent {
4491
4491
  constructor(service) {
4492
4492
  super();
4493
4493
  this.service = service;
4494
+ this.id = useRouteParam('id');
4494
4495
  this._entity = this.newEntity();
4495
4496
  }
4496
4497
  /**
@@ -4519,10 +4520,9 @@ class BaseFormComponent extends BaseComponent {
4519
4520
  */
4520
4521
  onInitForm(version) {
4521
4522
  this.loading.set(true);
4522
- const id = useRouteParams('id');
4523
- if (UUIDUtil.isValid(id())) {
4523
+ if (UUIDUtil.isValid(this.id())) {
4524
4524
  this.service
4525
- .getOne(id(), version)
4525
+ .getOne(this.id(), version)
4526
4526
  .pipe(takeUntilDestroyed(this.destroyRef), finalize$1(() => this.loading.set(false)))
4527
4527
  .subscribe({
4528
4528
  next: (entity) => {
@@ -13707,6 +13707,7 @@ class ExpansionPanel {
13707
13707
  this.name = input(this._uniqueId, ...(ngDevMode ? [{ debugName: "name" }] : []));
13708
13708
  this.label = input('', ...(ngDevMode ? [{ debugName: "label" }] : []));
13709
13709
  this.disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled", transform: booleanAttribute }] : [{ transform: booleanAttribute }]));
13710
+ this.required = input(false, ...(ngDevMode ? [{ debugName: "required", transform: booleanAttribute }] : [{ transform: booleanAttribute }]));
13710
13711
  this.initState = input('collapsed', ...(ngDevMode ? [{ debugName: "initState" }] : []));
13711
13712
  this.icon = input('', ...(ngDevMode ? [{ debugName: "icon" }] : []));
13712
13713
  this.svgIcon = input('', ...(ngDevMode ? [{ debugName: "svgIcon" }] : []));
@@ -13745,7 +13746,7 @@ class ExpansionPanel {
13745
13746
  this.expansionPanel()?.close();
13746
13747
  }
13747
13748
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: ExpansionPanel, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
13748
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: ExpansionPanel, isStandalone: true, selector: "gipi-expansion-panel", inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, initState: { classPropertyName: "initState", publicName: "initState", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, svgIcon: { classPropertyName: "svgIcon", publicName: "svgIcon", isSignal: true, isRequired: false, transformFunction: null }, iconFontSet: { classPropertyName: "iconFontSet", publicName: "iconFontSet", isSignal: true, isRequired: false, transformFunction: null }, iconSize: { classPropertyName: "iconSize", publicName: "iconSize", isSignal: true, isRequired: false, transformFunction: null }, iconVariation: { classPropertyName: "iconVariation", publicName: "iconVariation", isSignal: true, isRequired: false, transformFunction: null }, iconWeight: { classPropertyName: "iconWeight", publicName: "weight", isSignal: true, isRequired: false, transformFunction: null }, iconGrade: { classPropertyName: "iconGrade", publicName: "grade", isSignal: true, isRequired: false, transformFunction: null }, iconOptical: { classPropertyName: "iconOptical", publicName: "optical", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onClickEvent: "click", onFocusEvent: "focus", onBlurEvent: "blur", onOpenedEvent: "opened", onClosedEvent: "closed" }, host: { properties: { "attr.id": "id()", "attr.name": "name()" }, classAttribute: "g-expansion-panel" }, viewQueries: [{ propertyName: "expansionPanel", first: true, predicate: ["expansionPanel"], descendants: true, isSignal: true }], exportAs: ["gExpansionPanel"], ngImport: i0, template: `
13749
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: ExpansionPanel, isStandalone: true, selector: "gipi-expansion-panel", inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, initState: { classPropertyName: "initState", publicName: "initState", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, svgIcon: { classPropertyName: "svgIcon", publicName: "svgIcon", isSignal: true, isRequired: false, transformFunction: null }, iconFontSet: { classPropertyName: "iconFontSet", publicName: "iconFontSet", isSignal: true, isRequired: false, transformFunction: null }, iconSize: { classPropertyName: "iconSize", publicName: "iconSize", isSignal: true, isRequired: false, transformFunction: null }, iconVariation: { classPropertyName: "iconVariation", publicName: "iconVariation", isSignal: true, isRequired: false, transformFunction: null }, iconWeight: { classPropertyName: "iconWeight", publicName: "weight", isSignal: true, isRequired: false, transformFunction: null }, iconGrade: { classPropertyName: "iconGrade", publicName: "grade", isSignal: true, isRequired: false, transformFunction: null }, iconOptical: { classPropertyName: "iconOptical", publicName: "optical", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onClickEvent: "click", onFocusEvent: "focus", onBlurEvent: "blur", onOpenedEvent: "opened", onClosedEvent: "closed" }, host: { properties: { "attr.id": "id()", "attr.name": "name()" }, classAttribute: "g-expansion-panel" }, viewQueries: [{ propertyName: "expansionPanel", first: true, predicate: ["expansionPanel"], descendants: true, isSignal: true }], exportAs: ["gExpansionPanel"], ngImport: i0, template: `
13749
13750
  <mat-accordion
13750
13751
  displayMode="default"
13751
13752
  [multi]="true"
@@ -13762,7 +13763,12 @@ class ExpansionPanel {
13762
13763
  (blur)="onBlurEvent.emit($event)"
13763
13764
  >
13764
13765
  <mat-expansion-panel-header>
13765
- <mat-panel-title>{{ label() }}</mat-panel-title>
13766
+ <mat-panel-title>
13767
+ {{ label() }}
13768
+ @if (required()) {
13769
+ <span class="g-expansion-panel-required">Obrigatório</span>
13770
+ }
13771
+ </mat-panel-title>
13766
13772
 
13767
13773
  @if (icon() || svgIcon()) {
13768
13774
  <gipi-icon
@@ -13803,7 +13809,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
13803
13809
  (blur)="onBlurEvent.emit($event)"
13804
13810
  >
13805
13811
  <mat-expansion-panel-header>
13806
- <mat-panel-title>{{ label() }}</mat-panel-title>
13812
+ <mat-panel-title>
13813
+ {{ label() }}
13814
+ @if (required()) {
13815
+ <span class="g-expansion-panel-required">Obrigatório</span>
13816
+ }
13817
+ </mat-panel-title>
13807
13818
 
13808
13819
  @if (icon() || svgIcon()) {
13809
13820
  <gipi-icon
@@ -13828,7 +13839,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
13828
13839
  '[attr.name]': 'name()',
13829
13840
  class: 'g-expansion-panel',
13830
13841
  }, standalone: true, imports: [MatExpansionModule, IconModule] }]
13831
- }], ctorParameters: () => [], propDecorators: { expansionPanel: [{ type: i0.ViewChild, args: ['expansionPanel', { isSignal: true }] }], id: [{ type: i0.Input, args: [{ isSignal: true, alias: "id", required: false }] }], name: [{ type: i0.Input, args: [{ isSignal: true, alias: "name", required: false }] }], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], initState: [{ type: i0.Input, args: [{ isSignal: true, alias: "initState", required: false }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], svgIcon: [{ type: i0.Input, args: [{ isSignal: true, alias: "svgIcon", required: false }] }], iconFontSet: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconFontSet", required: false }] }], iconSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconSize", required: false }] }], iconVariation: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconVariation", required: false }] }], iconWeight: [{ type: i0.Input, args: [{ isSignal: true, alias: "weight", required: false }] }], iconGrade: [{ type: i0.Input, args: [{ isSignal: true, alias: "grade", required: false }] }], iconOptical: [{ type: i0.Input, args: [{ isSignal: true, alias: "optical", required: false }] }], onClickEvent: [{ type: i0.Output, args: ["click"] }], onFocusEvent: [{ type: i0.Output, args: ["focus"] }], onBlurEvent: [{ type: i0.Output, args: ["blur"] }], onOpenedEvent: [{ type: i0.Output, args: ["opened"] }], onClosedEvent: [{ type: i0.Output, args: ["closed"] }] } });
13842
+ }], ctorParameters: () => [], propDecorators: { expansionPanel: [{ type: i0.ViewChild, args: ['expansionPanel', { isSignal: true }] }], id: [{ type: i0.Input, args: [{ isSignal: true, alias: "id", required: false }] }], name: [{ type: i0.Input, args: [{ isSignal: true, alias: "name", required: false }] }], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], required: [{ type: i0.Input, args: [{ isSignal: true, alias: "required", required: false }] }], initState: [{ type: i0.Input, args: [{ isSignal: true, alias: "initState", required: false }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], svgIcon: [{ type: i0.Input, args: [{ isSignal: true, alias: "svgIcon", required: false }] }], iconFontSet: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconFontSet", required: false }] }], iconSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconSize", required: false }] }], iconVariation: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconVariation", required: false }] }], iconWeight: [{ type: i0.Input, args: [{ isSignal: true, alias: "weight", required: false }] }], iconGrade: [{ type: i0.Input, args: [{ isSignal: true, alias: "grade", required: false }] }], iconOptical: [{ type: i0.Input, args: [{ isSignal: true, alias: "optical", required: false }] }], onClickEvent: [{ type: i0.Output, args: ["click"] }], onFocusEvent: [{ type: i0.Output, args: ["focus"] }], onBlurEvent: [{ type: i0.Output, args: ["blur"] }], onOpenedEvent: [{ type: i0.Output, args: ["opened"] }], onClosedEvent: [{ type: i0.Output, args: ["closed"] }] } });
13832
13843
 
13833
13844
  class ExpansionPanelModule {
13834
13845
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: ExpansionPanelModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
@@ -24494,5 +24505,5 @@ function useRouteQueryParamsMap() {
24494
24505
  * Generated bundle index. Do not edit.
24495
24506
  */
24496
24507
 
24497
- export { ActionRow, ActionRowModule, AllowedPublicRoutesToken, AppMessagesToken, ArrayUtil, AutoFocusDirective, AutoFocusModule, Avatar, AvatarModule, BaseAppliedFilter, BaseAuthService, BaseAuthServiceToken, BaseAuthorityModel, BaseComponent, BaseControlValueAccessor, BaseCrudService, BaseFilterModel, BaseFormComponent, BaseFormDialogComponent, BaseFormDialogDataModel, BaseInput, BaseListComponent, BaseListDialogComponent, BaseListDialogDataModel, BaseMenuModel, BaseModel, BasePageModel, BaseQueryParams, BaseReportComponent, BaseService, BaseSortModel, BaseTokenModel, BaseUserModel, Button, ButtonGroup, ButtonGroupModule, ButtonModule, CAPITALIZE_ACRONYMS, CAPITALIZE_PREPOSITIONS, CURRENCY_OPTIONS_DEFAULT, CacheableService, Checkbox, CheckboxGroup, CheckboxModule, Chips, ChipsModule, ConfirmDialog, ConfirmDialogIcon, ConfirmDialogModel, ConfirmDialogModule, ConfirmDialogService, CssUtil, CurrencyDirective, CurrencyModule, CurrencyUtil, DEFAULT_MESSAGES, DatePicker, DatePickerModule, DateUtil, Debounce, DialogConfig, DialogService, DisableAutoFillDirective, DocumentPipe, DocumentUtil, EchartsConfigToken, EchartsDirective, EchartsModule, EmailUtil, Empty, EmptyModule, ExpansionPanel, ExpansionPanelModule, Fieldset, FieldsetModule, FileDragAndDrop, FileDragAndDropModule, FileSaverService, FilterListbox, FilterListboxModule, FilterPersistenceService, FilterService, FilterURLService, FlexLayoutDirective, FlexLayoutModule, FormField, FormFieldErrors, FormFieldInputDirective, FormFieldModule, FormFieldPrefixDirective, FormFieldSuffixDirective, FormWrapper, FormWrapperDialog, FormWrapperModule, HelpfulTip, HelpfulTipModule, Icon, IconModule, Input, InputCurrency, InputCurrencyModule, InputFile, InputFileModule, InputGroup, InputGroupAddon, InputGroupModule, InputModule, InputPhone, InputPhoneModule, Label, LabelModule, Loading, LoadingModule, LocalStorageToken, Lozenge, LozengeModule, MoneyPipe, NomalizeTextPipe, NumberToWordsUtil, NumberUtil, ObjectUtil, PAGINATOR_INTL_PT_BR, PageAdjustService, Paginator, PaginatorIntlToken, PaginatorModule, PaginatorPipe, PasswordRequirements, PasswordRequirementsModule, PasswordValidationUtil, PdfViewer, PdfViewerDialog, PdfViewerDialogModel, PdfViewerDialogModule, PdfViewerService, PhoneUtil, Popover, PopoverModule, PopoverTargetDirective, PopoverTriggerDirective, RadioGroup, RadioGroupModule, STATES_DATA, ScrollFadeDirective, ScrollFadeModule, SelectClientSide, SelectEnum, SelectModule, SelectServerSide, SessionStorageToken, Sidenav, SidenavContainer, SidenavContent, SidenavMenuItem, SidenavModule, Skeleton, SkeletonModule, SplitButton, SplitButtonModule, StateUtil, Step, Stepper, StepperModule, StringUtil, SvgRegisterService, Tab, TabGroup, Table, TableColumn, TableColumnBuilder, TableMenuItemContext, TableMenuItemContextBuilder, TableModule, TabsModule, Tag, TagModule, TextCapitalizeDirective, TextCapitalizeModule, TextEllipsisDirective, TextEllipsisModule, Textarea, TextareaModule, Toast, ToastIcon, ToastModel, ToastModule, ToastService, ToggleSwitch, ToggleSwitchModule, Toolbar, ToolbarModule, TooltipDirective, TooltipModule, TopNav, TopNavModule, TreeTable, TreeTableColumn, TreeTableColumnBuilder, TreeTableMenuItemContext, TreeTableMenuItemContextBuilder, TreeTableModule, UUIDUtil, UserProfile, UserProfileModule, animationFlyInOut, authChildGuard, authGuard, authInterceptor, eConfirmDialogTypes, eCurrencyInputMode, eMenuType, eSortDirection, eToastTypes, eTypeOperationCloseDialogEnum, eTypeOperationDialog, entityFilterSignal, errorInterceptor, filterSignal, provideAllowedPublicRoutes, provideAppMessages, provideBaseAuthService, provideEchartsCore, providePaginatorIntl, provideValueAccessor, publicChildGuard, publicGuard, rotateAnimation, rotateArrowTreeTableExpand, stateNamesMap, transformFilterSignal, useFilterPersistence, useLinkedFilter, useRouteParams, useRouteParamsMap, useRouteQueryParams, useRouteQueryParamsMap, useSearch };
24508
+ export { ActionRow, ActionRowModule, AllowedPublicRoutesToken, AppMessagesToken, ArrayUtil, AutoFocusDirective, AutoFocusModule, Avatar, AvatarModule, BaseAppliedFilter, BaseAuthService, BaseAuthServiceToken, BaseAuthorityModel, BaseComponent, BaseControlValueAccessor, BaseCrudService, BaseFilterModel, BaseFormComponent, BaseFormDialogComponent, BaseFormDialogDataModel, BaseInput, BaseListComponent, BaseListDialogComponent, BaseListDialogDataModel, BaseMenuModel, BaseModel, BasePageModel, BaseQueryParams, BaseReportComponent, BaseService, BaseSortModel, BaseTokenModel, BaseUserModel, Button, ButtonGroup, ButtonGroupModule, ButtonModule, CAPITALIZE_ACRONYMS, CAPITALIZE_PREPOSITIONS, CURRENCY_OPTIONS_DEFAULT, CacheableService, Checkbox, CheckboxGroup, CheckboxModule, Chips, ChipsModule, ConfirmDialog, ConfirmDialogIcon, ConfirmDialogModel, ConfirmDialogModule, ConfirmDialogService, CssUtil, CurrencyDirective, CurrencyModule, CurrencyUtil, DEFAULT_MESSAGES, DatePicker, DatePickerModule, DateUtil, Debounce, DialogConfig, DialogService, DisableAutoFillDirective, DocumentPipe, DocumentUtil, EchartsConfigToken, EchartsDirective, EchartsModule, EmailUtil, Empty, EmptyModule, ExpansionPanel, ExpansionPanelModule, Fieldset, FieldsetModule, FileDragAndDrop, FileDragAndDropModule, FileSaverService, FilterListbox, FilterListboxModule, FilterPersistenceService, FilterService, FilterURLService, FlexLayoutDirective, FlexLayoutModule, FormField, FormFieldErrors, FormFieldInputDirective, FormFieldModule, FormFieldPrefixDirective, FormFieldSuffixDirective, FormWrapper, FormWrapperDialog, FormWrapperModule, HelpfulTip, HelpfulTipModule, Icon, IconModule, Input, InputCurrency, InputCurrencyModule, InputFile, InputFileModule, InputGroup, InputGroupAddon, InputGroupModule, InputModule, InputPhone, InputPhoneModule, Label, LabelModule, Loading, LoadingModule, LocalStorageToken, Lozenge, LozengeModule, MoneyPipe, NomalizeTextPipe, NumberToWordsUtil, NumberUtil, ObjectUtil, PAGINATOR_INTL_PT_BR, PageAdjustService, Paginator, PaginatorIntlToken, PaginatorModule, PaginatorPipe, PasswordRequirements, PasswordRequirementsModule, PasswordValidationUtil, PdfViewer, PdfViewerDialog, PdfViewerDialogModel, PdfViewerDialogModule, PdfViewerService, PhoneUtil, Popover, PopoverModule, PopoverTargetDirective, PopoverTriggerDirective, RadioGroup, RadioGroupModule, STATES_DATA, ScrollFadeDirective, ScrollFadeModule, SelectClientSide, SelectEnum, SelectModule, SelectServerSide, SessionStorageToken, Sidenav, SidenavContainer, SidenavContent, SidenavMenuItem, SidenavModule, Skeleton, SkeletonModule, SplitButton, SplitButtonModule, StateUtil, Step, Stepper, StepperModule, StringUtil, SvgRegisterService, Tab, TabGroup, Table, TableColumn, TableColumnBuilder, TableMenuItemContext, TableMenuItemContextBuilder, TableModule, TabsModule, Tag, TagModule, TextCapitalizeDirective, TextCapitalizeModule, TextEllipsisDirective, TextEllipsisModule, Textarea, TextareaModule, Toast, ToastIcon, ToastModel, ToastModule, ToastService, ToggleSwitch, ToggleSwitchModule, Toolbar, ToolbarModule, TooltipDirective, TooltipModule, TopNav, TopNavModule, TreeTable, TreeTableColumn, TreeTableColumnBuilder, TreeTableMenuItemContext, TreeTableMenuItemContextBuilder, TreeTableModule, UUIDUtil, UserProfile, UserProfileModule, animationFlyInOut, authChildGuard, authGuard, authInterceptor, eConfirmDialogTypes, eCurrencyInputMode, eMenuType, eSortDirection, eToastTypes, eTypeOperationCloseDialogEnum, eTypeOperationDialog, entityFilterSignal, errorInterceptor, filterSignal, provideAllowedPublicRoutes, provideAppMessages, provideBaseAuthService, provideEchartsCore, providePaginatorIntl, provideValueAccessor, publicChildGuard, publicGuard, rotateAnimation, rotateArrowTreeTableExpand, stateNamesMap, transformFilterSignal, useFilterPersistence, useLinkedFilter, useRouteParam, useRouteParamsMap, useRouteQueryParams, useRouteQueryParamsMap, useSearch };
24498
24509
  //# sourceMappingURL=gipisistemas-ngx-core.mjs.map