cloud-ide-layout 1.0.28 → 1.0.30

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.
Files changed (13) hide show
  1. package/fesm2022/{cloud-ide-layout-cloud-ide-layout-CJzTf7P-.mjs → cloud-ide-layout-cloud-ide-layout-B6s3uvLN.mjs} +99 -34
  2. package/fesm2022/{cloud-ide-layout-cloud-ide-layout-CJzTf7P-.mjs.map → cloud-ide-layout-cloud-ide-layout-B6s3uvLN.mjs.map} +1 -1
  3. package/fesm2022/{cloud-ide-layout-drawer-theme.component-D89HAFms.mjs → cloud-ide-layout-drawer-theme.component-l_FmnhkN.mjs} +2 -2
  4. package/fesm2022/{cloud-ide-layout-drawer-theme.component-D89HAFms.mjs.map → cloud-ide-layout-drawer-theme.component-l_FmnhkN.mjs.map} +1 -1
  5. package/fesm2022/{cloud-ide-layout-floating-entity-selection.component-BLGbmXaB.mjs → cloud-ide-layout-floating-entity-selection.component-CMT71u85.mjs} +2 -2
  6. package/fesm2022/{cloud-ide-layout-floating-entity-selection.component-BLGbmXaB.mjs.map → cloud-ide-layout-floating-entity-selection.component-CMT71u85.mjs.map} +1 -1
  7. package/fesm2022/{cloud-ide-layout-home-wrapper.component-CVv3swkS.mjs → cloud-ide-layout-home-wrapper.component-D--JcFGT.mjs} +2 -2
  8. package/fesm2022/{cloud-ide-layout-home-wrapper.component-CVv3swkS.mjs.map → cloud-ide-layout-home-wrapper.component-D--JcFGT.mjs.map} +1 -1
  9. package/fesm2022/{cloud-ide-layout-sidedrawer-notes.component-Dhc7L8pg.mjs → cloud-ide-layout-sidedrawer-notes.component-BKhoj6_T.mjs} +2 -2
  10. package/fesm2022/{cloud-ide-layout-sidedrawer-notes.component-Dhc7L8pg.mjs.map → cloud-ide-layout-sidedrawer-notes.component-BKhoj6_T.mjs.map} +1 -1
  11. package/fesm2022/cloud-ide-layout.mjs +1 -1
  12. package/index.d.ts +27 -3
  13. package/package.json +1 -1
@@ -1,5 +1,5 @@
1
1
  import * as i0 from '@angular/core';
2
- import { Injectable, inject, signal, computed, effect, Component, ElementRef, HostListener, ChangeDetectionStrategy, ViewContainerRef, ViewChild, ViewChildren, input, InjectionToken, PLATFORM_ID, output } from '@angular/core';
2
+ import { Injectable, inject, signal, computed, effect, Component, ElementRef, HostListener, ChangeDetectionStrategy, ViewContainerRef, ViewChild, ViewChildren, viewChild, input, InjectionToken, PLATFORM_ID, output } from '@angular/core';
3
3
  import { HttpClient } from '@angular/common/http';
4
4
  import { cidePath, hostManagerRoutesUrl, coreRoutesUrl, commonRoutesUrl, designConfigRoutesUrl, generateStringFromObject } from 'cloud-ide-lms-model';
5
5
  import { Observable, throwError, of, BehaviorSubject, interval, take as take$1, firstValueFrom } from 'rxjs';
@@ -1266,7 +1266,7 @@ class CideLytFloatingEntitySelectionService {
1266
1266
  }
1267
1267
  try {
1268
1268
  // Use relative import to avoid circular dependency
1269
- const module = await import('./cloud-ide-layout-floating-entity-selection.component-BLGbmXaB.mjs');
1269
+ const module = await import('./cloud-ide-layout-floating-entity-selection.component-CMT71u85.mjs');
1270
1270
  if (module.CideLytFloatingEntitySelectionComponent) {
1271
1271
  this.containerService.registerComponent('entity-selection-header', module.CideLytFloatingEntitySelectionComponent);
1272
1272
  console.log('✅ Entity selection component registered successfully');
@@ -2741,8 +2741,8 @@ class CideLytSidedrawerWrapperComponent {
2741
2741
  }
2742
2742
  ngOnInit() {
2743
2743
  // Initialize the component map (You'd likely populate this from a config or service)
2744
- this.componentMap['drowar_notes'] = () => import('./cloud-ide-layout-sidedrawer-notes.component-Dhc7L8pg.mjs').then(m => m.CideLytSidedrawerNotesComponent);
2745
- this.componentMap['drawer_theme'] = () => import('./cloud-ide-layout-drawer-theme.component-D89HAFms.mjs').then(m => m.CideLytDrawerThemeComponent);
2744
+ this.componentMap['drowar_notes'] = () => import('./cloud-ide-layout-sidedrawer-notes.component-BKhoj6_T.mjs').then(m => m.CideLytSidedrawerNotesComponent);
2745
+ this.componentMap['drawer_theme'] = () => import('./cloud-ide-layout-drawer-theme.component-l_FmnhkN.mjs').then(m => m.CideLytDrawerThemeComponent);
2746
2746
  }
2747
2747
  async loadComponent(configFor) {
2748
2748
  console.log('🔍 SIDEDRAWER - Loading component:', configFor, 'Current tab:', this.currentTabId);
@@ -3119,12 +3119,58 @@ var cloudIdeLayout_component = /*#__PURE__*/Object.freeze({
3119
3119
  });
3120
3120
 
3121
3121
  class CideLytSharedWrapperComponent {
3122
- breadcrumb;
3122
+ breadcrumb = viewChild(CideEleBreadcrumbComponent, ...(ngDevMode ? [{ debugName: "breadcrumb" }] : []));
3123
3123
  shared_wrapper_setup_param = input({}, ...(ngDevMode ? [{ debugName: "shared_wrapper_setup_param" }] : []));
3124
+ breadcrumb_data = input([], ...(ngDevMode ? [{ debugName: "breadcrumb_data" }] : []));
3124
3125
  page_data = {};
3125
3126
  sharedService = inject(CideLytSharedService);
3126
3127
  sidedrawerService = inject(CideLytSidedrawerService);
3127
3128
  appState = inject(AppStateHelperService);
3129
+ // Signal for additional breadcrumb items that will be appended after Module > Current Page
3130
+ additionalBreadcrumbItems = signal([], ...(ngDevMode ? [{ debugName: "additionalBreadcrumbItems" }] : []));
3131
+ // Computed signal that combines default breadcrumb with additional items
3132
+ fullBreadcrumbItems = computed(() => {
3133
+ const moduleInfo = this.appState.getActiveModuleInfo();
3134
+ const pageCode = this.shared_wrapper_setup_param()?.sypg_page_code;
3135
+ // Default breadcrumb items
3136
+ const defaultItems = [];
3137
+ // Add module if available
3138
+ if (moduleInfo?.title) {
3139
+ defaultItems.push({
3140
+ id: moduleInfo.id || 'module',
3141
+ label: moduleInfo.title,
3142
+ icon: moduleInfo.icon || undefined,
3143
+ url: moduleInfo.path || undefined
3144
+ });
3145
+ }
3146
+ // Add current page
3147
+ const currentPageTitle = this.page_data?.page?.sypg_title || pageCode || 'Current';
3148
+ defaultItems.push({
3149
+ id: 'current-page',
3150
+ label: currentPageTitle,
3151
+ icon: undefined,
3152
+ url: undefined
3153
+ });
3154
+ // Append additional items from input signal
3155
+ const inputBreadcrumbData = this.breadcrumb_data();
3156
+ if (inputBreadcrumbData.length > 0) {
3157
+ return [...defaultItems, ...inputBreadcrumbData];
3158
+ }
3159
+ // Append additional items from internal signal (for backward compatibility)
3160
+ return [...defaultItems, ...this.additionalBreadcrumbItems()];
3161
+ }, ...(ngDevMode ? [{ debugName: "fullBreadcrumbItems" }] : []));
3162
+ constructor() {
3163
+ // Watch for changes in breadcrumb data and update breadcrumb component
3164
+ effect(() => {
3165
+ const breadcrumbRef = this.breadcrumb();
3166
+ const items = this.fullBreadcrumbItems();
3167
+ console.log('🍞 Shared wrapper breadcrumb effect triggered:', items);
3168
+ if (breadcrumbRef && items.length > 0) {
3169
+ breadcrumbRef.updateItems(items);
3170
+ console.log('🍞 Breadcrumb updated with items:', items);
3171
+ }
3172
+ });
3173
+ }
3128
3174
  ngOnInit() {
3129
3175
  // Load and process page data using modern approach
3130
3176
  if (this.shared_wrapper_setup_param()?.sypg_page_code) {
@@ -3146,26 +3192,7 @@ class CideLytSharedWrapperComponent {
3146
3192
  const pageId = page_data_response?.data?.page?._id || '';
3147
3193
  const themeId = page_data_response?.data?.theme?._id || '';
3148
3194
  this.sidedrawerService.setContext(pageId, themeId);
3149
- // Fetch breadcrumb items by page code and assign to breadcrumb
3150
- const pageCode = this.shared_wrapper_setup_param()?.sypg_page_code;
3151
- if (this.breadcrumb && pageCode) {
3152
- this.breadcrumb.setLoading(true);
3153
- this.sharedService.getBreadcrumbNavigation(pageCode).subscribe({
3154
- next: (navItems) => {
3155
- const items = navItems.map(n => ({ id: n.id, label: n.label, icon: n.icon, url: n.path }));
3156
- const breadcrumbRef = this.breadcrumb;
3157
- if (breadcrumbRef) {
3158
- breadcrumbRef.updateItems(items);
3159
- breadcrumbRef.setLoading(false);
3160
- }
3161
- },
3162
- error: () => {
3163
- const breadcrumbRef = this.breadcrumb;
3164
- if (breadcrumbRef)
3165
- breadcrumbRef.setLoading(false);
3166
- }
3167
- });
3168
- }
3195
+ // Breadcrumb will be updated automatically by the effect when fullBreadcrumbItems changes
3169
3196
  },
3170
3197
  error: (err) => {
3171
3198
  console.error('❌ SHARED WRAPPER: Error loading page data:', err);
@@ -3173,16 +3200,51 @@ class CideLytSharedWrapperComponent {
3173
3200
  });
3174
3201
  }
3175
3202
  }
3203
+ /**
3204
+ * Add additional breadcrumb items that will be appended after the default Module > Current Page path
3205
+ * @param items Array of breadcrumb items to append
3206
+ */
3207
+ addBreadcrumbItems(items) {
3208
+ this.additionalBreadcrumbItems.set(items);
3209
+ // Update breadcrumb immediately
3210
+ const breadcrumbRef = this.breadcrumb();
3211
+ if (breadcrumbRef) {
3212
+ const fullItems = this.fullBreadcrumbItems();
3213
+ breadcrumbRef.updateItems(fullItems);
3214
+ }
3215
+ }
3216
+ /**
3217
+ * Clear additional breadcrumb items (keeps only default Module > Current Page)
3218
+ */
3219
+ clearAdditionalBreadcrumbItems() {
3220
+ this.additionalBreadcrumbItems.set([]);
3221
+ // Update breadcrumb immediately
3222
+ const breadcrumbRef = this.breadcrumb();
3223
+ if (breadcrumbRef) {
3224
+ const fullItems = this.fullBreadcrumbItems();
3225
+ breadcrumbRef.updateItems(fullItems);
3226
+ }
3227
+ }
3228
+ /**
3229
+ * Set additional breadcrumb items (replaces any existing additional items)
3230
+ * @param items Array of breadcrumb items to set
3231
+ */
3232
+ setBreadcrumbItems(items) {
3233
+ this.additionalBreadcrumbItems.set(items);
3234
+ // Update breadcrumb immediately
3235
+ const breadcrumbRef = this.breadcrumb();
3236
+ if (breadcrumbRef) {
3237
+ const fullItems = this.fullBreadcrumbItems();
3238
+ breadcrumbRef.updateItems(fullItems);
3239
+ }
3240
+ }
3176
3241
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.7", ngImport: i0, type: CideLytSharedWrapperComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
3177
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.1.7", type: CideLytSharedWrapperComponent, isStandalone: true, selector: "cide-lyt-shared-wrapper", inputs: { shared_wrapper_setup_param: { classPropertyName: "shared_wrapper_setup_param", publicName: "shared_wrapper_setup_param", isSignal: true, isRequired: false, transformFunction: null } }, viewQueries: [{ propertyName: "breadcrumb", first: true, predicate: CideEleBreadcrumbComponent, descendants: true }], ngImport: i0, template: "<cide-ele-breadcrumb style=\"modern\" [compact]=\"true\"></cide-ele-breadcrumb>\n\n<ng-content></ng-content>\n", styles: [""], dependencies: [{ kind: "component", type: CideEleBreadcrumbComponent, selector: "cide-ele-breadcrumb", inputs: ["items", "style", "separator", "showHomeIcon", "homeIcon", "maxItems", "showDropdownOnOverflow", "dropdownOptions", "clickableItems", "showTooltips", "responsive", "compact", "animated", "loadingInput", "disabled", "contextId", "pageCode"], outputs: ["itemClick", "dropdownOptionClick", "homeClick"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
3242
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "20.1.7", type: CideLytSharedWrapperComponent, isStandalone: true, selector: "cide-lyt-shared-wrapper", inputs: { shared_wrapper_setup_param: { classPropertyName: "shared_wrapper_setup_param", publicName: "shared_wrapper_setup_param", isSignal: true, isRequired: false, transformFunction: null }, breadcrumb_data: { classPropertyName: "breadcrumb_data", publicName: "breadcrumb_data", isSignal: true, isRequired: false, transformFunction: null } }, viewQueries: [{ propertyName: "breadcrumb", first: true, predicate: CideEleBreadcrumbComponent, descendants: true, isSignal: true }], ngImport: i0, template: "<div class=\"tw-sticky tw-top-0 tw-z-50 tw-bg-white tw-border-b tw-border-gray-200 tw-shadow-sm\">\n <div class=\"tw-flex tw-items-center tw-justify-between tw-px-4 tw-py-0.5\">\n <div class=\"tw-flex-1\">\n <cide-ele-breadcrumb style=\"modern\" [compact]=\"true\"></cide-ele-breadcrumb>\n </div>\n <div class=\"tw-flex-shrink-0 tw-ml-4\">\n <ng-content select=\"[breadcrumb-actions]\"></ng-content>\n </div>\n </div>\n</div>\n\n<ng-content></ng-content>", styles: [""], dependencies: [{ kind: "component", type: CideEleBreadcrumbComponent, selector: "cide-ele-breadcrumb", inputs: ["items", "style", "separator", "showHomeIcon", "homeIcon", "maxItems", "showDropdownOnOverflow", "dropdownOptions", "clickableItems", "showTooltips", "responsive", "compact", "animated", "loadingInput", "disabled", "contextId", "pageCode"], outputs: ["itemClick", "dropdownOptionClick", "homeClick"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
3178
3243
  }
3179
3244
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.7", ngImport: i0, type: CideLytSharedWrapperComponent, decorators: [{
3180
3245
  type: Component,
3181
- args: [{ selector: 'cide-lyt-shared-wrapper', standalone: true, imports: [CideEleBreadcrumbComponent], changeDetection: ChangeDetectionStrategy.OnPush, template: "<cide-ele-breadcrumb style=\"modern\" [compact]=\"true\"></cide-ele-breadcrumb>\n\n<ng-content></ng-content>\n" }]
3182
- }], propDecorators: { breadcrumb: [{
3183
- type: ViewChild,
3184
- args: [CideEleBreadcrumbComponent]
3185
- }] } });
3246
+ args: [{ selector: 'cide-lyt-shared-wrapper', standalone: true, imports: [CideEleBreadcrumbComponent], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"tw-sticky tw-top-0 tw-z-50 tw-bg-white tw-border-b tw-border-gray-200 tw-shadow-sm\">\n <div class=\"tw-flex tw-items-center tw-justify-between tw-px-4 tw-py-0.5\">\n <div class=\"tw-flex-1\">\n <cide-ele-breadcrumb style=\"modern\" [compact]=\"true\"></cide-ele-breadcrumb>\n </div>\n <div class=\"tw-flex-shrink-0 tw-ml-4\">\n <ng-content select=\"[breadcrumb-actions]\"></ng-content>\n </div>\n </div>\n</div>\n\n<ng-content></ng-content>" }]
3247
+ }], ctorParameters: () => [] });
3186
3248
 
3187
3249
  const layoutRoutes = {
3188
3250
  path: "control-panel",
@@ -3196,7 +3258,7 @@ const layoutControlPannelChildRoutes = [{
3196
3258
  },
3197
3259
  {
3198
3260
  path: "home",
3199
- loadComponent: () => import('./cloud-ide-layout-home-wrapper.component-CVv3swkS.mjs').then(c => c.CideLytHomeWrapperComponent),
3261
+ loadComponent: () => import('./cloud-ide-layout-home-wrapper.component-D--JcFGT.mjs').then(c => c.CideLytHomeWrapperComponent),
3200
3262
  canActivate: [authGuard],
3201
3263
  data: {
3202
3264
  reuseTab: true, // For CustomRouteReuseStrategy
@@ -3939,7 +4001,10 @@ class CideLytFloatingEntityRightsSharingComponent {
3939
4001
  async loadEntities() {
3940
4002
  this.entitiesLoading.set(true);
3941
4003
  try {
3942
- const payload = { syen_id: "" };
4004
+ const payload = {
4005
+ syen_id: ""
4006
+ // Note here list of entity is got from loggied in user id to which he is mapped
4007
+ };
3943
4008
  const resp = await firstValueFrom(this.entityService.getEntityList(payload));
3944
4009
  const list = resp?.data || [];
3945
4010
  this.entities.set(list);
@@ -4760,4 +4825,4 @@ var floatingEntityRightsSharing_component = /*#__PURE__*/Object.freeze({
4760
4825
  */
4761
4826
 
4762
4827
  export { AppStateHelperService as A, CideLytSharedWrapperComponent as C, ENVIRONMENT_CONFIG as E, CideLytSidebarService as a, CideLytRequestService as b, CideLytSidedrawerService as c, CideLytThemeService as d, AppStateService as e, CloudIdeLayoutService as f, CloudIdeLayoutComponent as g, CideLytSharedService as h, layoutControlPannelChildRoutes as i, CustomRouteReuseStrategy as j, CideLytUserStatusService as k, layoutRoutes as l, CacheManagerService as m, CideLytFileManagerService as n, CideLytFloatingEntityRightsSharingComponent as o, processThemeVariable as p, CideLytFloatingEntityRightsSharingService as q, setCSSVariable as s, themeFactory as t };
4763
- //# sourceMappingURL=cloud-ide-layout-cloud-ide-layout-CJzTf7P-.mjs.map
4828
+ //# sourceMappingURL=cloud-ide-layout-cloud-ide-layout-B6s3uvLN.mjs.map