Skip to content

Commit

Permalink
fix(primevue): Add context menu styling in Classic theme
Browse files Browse the repository at this point in the history
  • Loading branch information
Corb3nik committed Sep 3, 2024
1 parent 9081e3e commit 29afe24
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 1 deletion.
2 changes: 1 addition & 1 deletion packages/primevue/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@caido/primevue",
"version": "0.0.1",
"version": "0.0.2",
"description": "Primevue themes for Caido",
"main": "dist/primevue.mjs",
"types": "dist/types/index.d.ts",
Expand Down
15 changes: 15 additions & 0 deletions packages/primevue/src/classic/components/contextmenu.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import {defineComponent} from "./utils";

export default defineComponent({
tokens: {
contextmenu: {
root: {
borderColor: '{gray.700}',
background: '{gray.900}'
},
separator: {
borderColor: '{gray.700}'
}
},
}
});
4 changes: 4 additions & 0 deletions packages/primevue/src/classic/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import datatable from "./components/datatable";
import menubar from "./components/menubar";
import column from "./components/column";
import checkbox from "./components/checkbox";
import contextmenu from "./components/contextmenu";

export const ClassicTheme = definePreset(Aura, {
primitive: {
Expand Down Expand Up @@ -126,6 +127,7 @@ export const ClassicTheme = definePreset(Aura, {
},
highlight: {
background: 'rgba(255, 255, 255, 0.2)',
focusBackground: 'color-mix(in srgb, {secondary.400}, transparent 76%)',
},
formField: {
focusBorderColor: '{secondary.color}',
Expand All @@ -146,6 +148,7 @@ export const ClassicTheme = definePreset(Aura, {
...menubar.tokens,
...splitter.passthrough,
...checkbox.tokens,
...contextmenu.tokens,
}
});

Expand All @@ -156,4 +159,5 @@ export const ClassicThemePassthrough = {
...menubar.passthrough,
...splitter.passthrough,
...checkbox.passthrough,
...contextmenu.passthrough,
} as const

0 comments on commit 29afe24

Please sign in to comment.