@keenmate/pure-admin-core 2.3.3 → 2.3.5

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/README.md CHANGED
@@ -2,16 +2,15 @@
2
2
 
3
3
  Lightweight, data-focused CSS/SCSS admin framework with Corporate theme as default.
4
4
 
5
- ## What's New in 2.3.3
5
+ ## What's New in 2.3.5
6
6
 
7
- - **Command palette rewrite** — Multi-step command wizards (`/deploy`, `/assign`, `/go`, `/theme`), context search (`:p`, `:u`, `:o`), global search, inline/tokens display modes matching keen-pure-admin
8
- - **Dark theme fixes** — Command palette loading overlay, key badges, and item badges all use CSS variables instead of SCSS defaults stuck on light mode
7
+ - **Navbar alignment fix** — `__end` section pushed to right edge via `margin-inline-start: auto`, works without `__center` spacer
8
+ - **Scroll-lock fix** — Panel/modal open no longer hides scrollbar (`overflow-y: scroll` instead of `hidden`)
9
9
 
10
- ## What's New in 2.3.2
10
+ ## What's New in 2.3.4
11
11
 
12
- - **Themeable border-radius via CSS variables** — All components now use `var(--pa-border-radius)`. Themes override in `:root` (same pattern as colors). Fixes long-standing issue where `@use` module isolation prevented theme control of border-radius
13
- - **Outline-secondary button contrast** — New `--pa-btn-secondary-outline-color` variable, readable on all dark themes
14
- - **Split button dropdown rework** — Two-container pattern (`__menu` + `__menu-inner`) matching web-multiselect. New `__item-row` element for rows with action buttons. Container handles `overflow: hidden` + `border-radius`
12
+ - **Command palette home screen & hotkeys** — Opens with categorized commands and search contexts. Alt+D/A/G/T hotkeys jump directly into commands. Global search finds commands alongside data. Form codes for quick `/go` navigation.
13
+ - **Dropdown z-index fix** — Split button menus no longer go under sidebar/header
15
14
  - **Removed hover lift** — `translateY(-1px)` removed from buttons and stat cards for consistency
16
15
 
17
16
  ## Installation
@@ -338,26 +337,65 @@ Works with both `pa-table` and `web-grid` component. First/last columns automati
338
337
  - `.pa-modal--primary/success/danger/warning` - Themed headers
339
338
 
340
339
  ### Command Palette
341
- - `.pa-command-palette` - Base container (add `--active` to show)
340
+
341
+ macOS Spotlight-style search with multi-step commands, context search, and global search. Opens with `Ctrl+K` / `Cmd+K`.
342
+
343
+ #### Behavior
344
+
345
+ **Home Screen** — On open, displays a categorized list of available commands (with hotkey badges) and search contexts. Items are clickable. Typing immediately filters or switches to the appropriate mode.
346
+
347
+ **Three Input Modes:**
348
+
349
+ | Prefix | Mode | Behavior |
350
+ |--------|------|----------|
351
+ | `/` | Commands | Shows matching commands. Exact match + space enters the command wizard. |
352
+ | `:` | Context search | Shows matching search contexts. Exact match + space enters scoped search with debounced filtering. |
353
+ | (none) | Global search | Searches across all categories (commands, contexts, and data). Results limited to ~3 per category. |
354
+
355
+ **Multi-step Commands** — Commands define an array of `steps`. Each step has `getOptions(query, previousSelections)` returning filterable options. Steps can be conditional (`shouldShow(selections)`), support free-text entry (`freeText: true`), and have prompts displayed between selections (e.g., "in", "to", "as"). The command's `onComplete(selections)` fires after all steps.
356
+
357
+ **Fuzzy Matching** — Commands and contexts match on `shortcut`, `aliases`, and `name`. Matching is bidirectional: typing `/d` finds `/deploy`, and typing `/deploy` finds `/d`.
358
+
359
+ **Form Codes** — Step options can have a `code` property (e.g., `"24"` for Alerts). The `filterOpts` helper matches on `label`, `description`, and exact `code` — enabling quick navigation by numeric codes common in business applications.
360
+
361
+ **Display Styles:**
362
+
363
+ - **Inline** — Everything in one input: `/deploy in Production branch main`. The input shows the full command string with prompts and selected values concatenated.
364
+ - **Tokens** — Selections render as `pa-badge` chips in `__tokens` container above the input. Each badge has a `×` remove button to rewind to that step. The input only contains the current step's query. The command shortcut is the first badge.
365
+
366
+ **Hotkeys** — Commands can define a `hotkey` (e.g., `"Alt+D"`). These work globally (palette closed) and inside the palette (on the home screen). The hotkey opens the palette and enters the command directly, skipping the command list.
367
+
368
+ **Context Label** — `__context` element shows the active command name (e.g., "Assign to User") or search context (e.g., "Searching in Products"). Positioned inside `__input-wrapper` relative to the input.
369
+
370
+ **Search Highlighting** — Matching text in result titles is wrapped in `<mark>` elements, styled with `--pa-command-palette-highlight-bg` and `--pa-command-palette-highlight-text`. Highlights persist during keyboard navigation.
371
+
372
+ **Keyboard:** `↑↓` navigate, `Enter`/`Tab` select (or submit free text), `Esc` close, `Alt+key` command hotkeys.
373
+
374
+ #### CSS Classes
375
+
376
+ - `.pa-command-palette` - Base container (`--active` to show)
342
377
  - `.pa-command-palette__backdrop` - Overlay backdrop
343
378
  - `.pa-command-palette__container` - Modal dialog
344
- - `.pa-command-palette__search` - Search area (input + tokens + context)
345
- - `.pa-command-palette__tokens` - Token badges container (for token display mode)
379
+ - `.pa-command-palette__search` - Search area (tokens + input-wrapper)
380
+ - `.pa-command-palette__tokens` - Token badges container (hidden when empty via `:empty`)
346
381
  - `.pa-command-palette__input-wrapper` - Wraps input + context label (positioning anchor)
347
382
  - `.pa-command-palette__input` - Search input
348
- - `.pa-command-palette__context` - Context label (e.g., "Assign to User", "Searching in Products")
349
- - `.pa-command-palette__results` - Scrollable results area
350
- - `.pa-command-palette__item` - Result row (`--active` for keyboard-highlighted)
383
+ - `.pa-command-palette__context` - Context label (`--visible` to show)
384
+ - `.pa-command-palette__results` - Scrollable results area (`--loading` for overlay)
385
+ - `.pa-command-palette__home` - Home screen container
386
+ - `.pa-command-palette__home-section` - Section with border-top separator
387
+ - `.pa-command-palette__home-heading` - Uppercase section heading
388
+ - `.pa-command-palette__item` - Result row (`--active` for keyboard highlight)
351
389
  - `.pa-command-palette__item-icon` - Item icon
352
390
  - `.pa-command-palette__item-content` - Title + subtitle wrapper
353
- - `.pa-command-palette__item-title` - Item title (supports `<mark>` for search highlights)
354
- - `.pa-command-palette__item-meta` - Subtitle/metadata
355
- - `.pa-command-palette__preview` - Command step preview text
356
- - `.pa-command-palette__footer` - Keyboard hints bar
357
- - `.pa-command-palette__key` - Keyboard shortcut badge
391
+ - `.pa-command-palette__item-title` - Title (supports `<mark>` for highlights)
392
+ - `.pa-command-palette__item-meta` - Subtitle/metadata (shows `[code]` prefix when present)
393
+ - `.pa-command-palette__shortcut` - Hotkey badge group (flex container)
394
+ - `.pa-command-palette__key` - Keyboard key badge (themeable via `--pa-command-palette-key-bg/key-text`)
358
395
  - `.pa-command-palette__token-prompt` - Step prompt text between token badges
359
- - **Modes:** `/` commands, `:` context search, plain text global search
360
- - **Display styles:** Inline (everything in input) or Tokens (selections as badges)
396
+ - `.pa-command-palette__footer` - Keyboard hints bar
397
+ - `.pa-command-palette__empty` - Empty state message
398
+ - `.pa-command-palette__loader` - Loading spinner + text
361
399
 
362
400
  ### Toasts
363
401
  - `.pa-toast` - Base toast
package/dist/css/main.css CHANGED
@@ -2826,6 +2826,7 @@ body.pa-container-2xl .pa-navbar {
2826
2826
  align-items: center;
2827
2827
  gap: 1.6rem;
2828
2828
  flex-shrink: 0;
2829
+ margin-inline-start: auto;
2829
2830
  }
2830
2831
 
2831
2832
  /* ========================================
@@ -6230,7 +6231,7 @@ a.pa-card p {
6230
6231
  border: 1px solid var(--pa-border-color);
6231
6232
  border-radius: var(--pa-border-radius);
6232
6233
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
6233
- z-index: 1000;
6234
+ z-index: 7500;
6234
6235
  display: none;
6235
6236
  flex-direction: column;
6236
6237
  padding: 0.4rem 0;
@@ -7819,7 +7820,7 @@ a.pa-card p {
7819
7820
  border: 1px solid var(--pa-border-color);
7820
7821
  border-radius: var(--pa-border-radius);
7821
7822
  box-shadow: 0 0 80px rgba(0, 0, 0, 0.15);
7822
- z-index: 1000;
7823
+ z-index: 7500;
7823
7824
  overflow: hidden;
7824
7825
  }
7825
7826
  .pa-btn-split__menu--open {
@@ -8594,7 +8595,7 @@ a.pa-card p {
8594
8595
  border: 1px solid var(--pa-border-color);
8595
8596
  border-radius: var(--pa-border-radius);
8596
8597
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
8597
- z-index: 1060;
8598
+ z-index: 7600;
8598
8599
  }
8599
8600
  .pa-popover__content[data-show] {
8600
8601
  display: block;
@@ -13909,6 +13910,28 @@ code {
13909
13910
  pointer-events: none;
13910
13911
  z-index: 1;
13911
13912
  }
13913
+ .pa-command-palette__home {
13914
+ padding: 0.8rem 0;
13915
+ }
13916
+ .pa-command-palette__home-section:not(:first-child) {
13917
+ border-top: 1px solid var(--pa-border-color);
13918
+ margin-top: 0.4rem;
13919
+ padding-top: 0.4rem;
13920
+ }
13921
+ .pa-command-palette__home-heading {
13922
+ padding: 0.4rem 0.8rem;
13923
+ font-size: 1rem;
13924
+ font-weight: 600;
13925
+ color: var(--pa-text-color-2);
13926
+ text-transform: uppercase;
13927
+ letter-spacing: 0.05em;
13928
+ }
13929
+ .pa-command-palette__shortcut {
13930
+ display: flex;
13931
+ align-items: center;
13932
+ gap: 0.4rem;
13933
+ flex-shrink: 0;
13934
+ }
13912
13935
  .pa-command-palette__empty {
13913
13936
  padding: 4.8rem 0.8rem;
13914
13937
  text-align: center;
@@ -14003,8 +14026,8 @@ code {
14003
14026
  border: 1px solid var(--pa-border-color);
14004
14027
  border-radius: var(--pa-border-radius-sm);
14005
14028
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
14006
- font-weight: 500;
14007
- font-size: 1rem;
14029
+ font-weight: var(--pa-command-palette-key-font-weight);
14030
+ font-size: var(--pa-command-palette-key-font-size);
14008
14031
  line-height: 1;
14009
14032
  }
14010
14033
  .pa-command-palette__section {
@@ -16888,7 +16911,7 @@ html.font-size-xlarge {
16888
16911
  }
16889
16912
 
16890
16913
  .pa-scroll-lock {
16891
- overflow: hidden !important;
16914
+ overflow-y: scroll !important;
16892
16915
  }
16893
16916
 
16894
16917
  .cursor-pointer {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@keenmate/pure-admin-core",
3
- "version": "2.3.3",
3
+ "version": "2.3.5",
4
4
  "description": "Lightweight, data-focused HTML/CSS admin framework built with PureCSS foundation and comprehensive component system",
5
5
  "style": "dist/css/main.css",
6
6
  "exports": {
@@ -461,6 +461,8 @@
461
461
  --pa-command-palette-highlight-text: #{$command-palette-highlight-text};
462
462
  --pa-command-palette-key-bg: #{$subtle-bg};
463
463
  --pa-command-palette-key-text: #{$text-color-1};
464
+ --pa-command-palette-key-font-size: #{$font-size-xs};
465
+ --pa-command-palette-key-font-weight: #{$font-weight-semibold};
464
466
 
465
467
  // =========================================================================
466
468
  // MULTISELECT COLORS
@@ -156,6 +156,35 @@
156
156
  }
157
157
  }
158
158
 
159
+ // Home screen (idle state)
160
+ &__home {
161
+ padding: $spacing-sm 0;
162
+ }
163
+
164
+ &__home-section {
165
+ &:not(:first-child) {
166
+ border-top: $border-width-base solid var(--pa-border-color);
167
+ margin-top: $spacing-xs;
168
+ padding-top: $spacing-xs;
169
+ }
170
+ }
171
+
172
+ &__home-heading {
173
+ padding: $spacing-xs $command-palette-input-padding-h;
174
+ font-size: $font-size-2xs;
175
+ font-weight: $font-weight-semibold;
176
+ color: var(--pa-text-color-2);
177
+ text-transform: uppercase;
178
+ letter-spacing: 0.05em;
179
+ }
180
+
181
+ &__shortcut {
182
+ display: flex;
183
+ align-items: center;
184
+ gap: $spacing-xs;
185
+ flex-shrink: 0;
186
+ }
187
+
159
188
  // Empty state
160
189
  &__empty {
161
190
  padding: $command-palette-empty-padding-v $command-palette-input-padding-h;
@@ -271,8 +300,8 @@
271
300
  border: $border-width-base solid var(--pa-border-color);
272
301
  border-radius: var(--pa-border-radius-sm);
273
302
  font-family: $body-font-family;
274
- font-weight: $font-weight-medium;
275
- font-size: $font-size-2xs;
303
+ font-weight: var(--pa-command-palette-key-font-weight);
304
+ font-size: var(--pa-command-palette-key-font-size);
276
305
  line-height: 1;
277
306
  }
278
307
 
@@ -139,7 +139,7 @@ html.font-size-xlarge {
139
139
  // Scroll lock - prevents body scrolling when overlays are open
140
140
  // Apply to <body> element via JavaScript
141
141
  .pa-scroll-lock {
142
- overflow: hidden !important;
142
+ overflow-y: scroll !important;
143
143
  }
144
144
 
145
145
  // Cursor utilities
@@ -80,4 +80,5 @@ body.pa-container-2xl .pa-navbar {
80
80
  align-items: center;
81
81
  gap: $spacing-base;
82
82
  flex-shrink: 0;
83
+ margin-inline-start: auto;
83
84
  }
@@ -17,8 +17,8 @@ $z-index-toast: 8000 !default;
17
17
  $z-index-tooltip: 9000 !default;
18
18
 
19
19
  // Additional z-index values
20
- $z-index-dropdown: 1000 !default;
21
- $z-index-popover: 1060 !default;
20
+ $z-index-dropdown: 7500 !default;
21
+ $z-index-popover: 7600 !default;
22
22
  $z-index-loader: 10 !default;
23
23
  $z-index-command-palette: 10500 !default;
24
24
  $z-index-settings-panel: 10000 !default;