Skip to content

Commit

Permalink
fix colors
Browse files Browse the repository at this point in the history
  • Loading branch information
ruggi committed Feb 14, 2024
1 parent 94f0078 commit aba8fd4
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 7 deletions.
11 changes: 9 additions & 2 deletions utopia-remix/app/components/projectActionContextMenu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import { ProjectWithoutContent } from '../types'
import { assertNever } from '../util/assertNever'
import { projectEditorLink } from '../util/links'
import { contextMenuItem } from '../styles/contextMenuItem.css'
import { colors } from '../styles/sprinkles.css'

type ContextMenuEntry =
| {
Expand Down Expand Up @@ -121,19 +122,25 @@ export const ProjectContextMenu = React.memo(
<DropdownMenu.Content
style={{
background: 'white',
padding: 10,
padding: 4,
boxShadow: '2px 3px 4px #dddddd',
border: '1px solid #ccc',
borderRadius: 4,
display: 'flex',
flexDirection: 'column',
gap: 4,
minWidth: 100,
}}
sideOffset={5}
>
{menuEntries.map((entry, index) => {
if (entry === 'separator') {
return <DropdownMenu.Separator key={`separator-${index}`} />
return (
<DropdownMenu.Separator
key={`separator-${index}`}
style={{ backgroundColor: colors.separator, height: 1 }}
/>
)
}
return (
<DropdownMenu.Item
Expand Down
13 changes: 9 additions & 4 deletions utopia-remix/app/styles/contextMenuItem.css.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { recipe } from '@vanilla-extract/recipes'
import { sprinkles } from './sprinkles.css'
import { colors, sprinkles } from './sprinkles.css'

export const contextMenuItem = recipe({
base: [
Expand All @@ -8,9 +8,14 @@ export const contextMenuItem = recipe({
color: 'lightModeBlack',
}),
{
padding: '4px 4px',
cursor: 'default',
border: 'none',
outline: 'none',
padding: '6px 8px',
cursor: 'pointer',
border: 'none !important',
':hover': {
backgroundColor: colors.primary,
color: 'white',
},
},
],
})
3 changes: 2 additions & 1 deletion utopia-remix/app/styles/sprinkles.css.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import { defineProperties, createSprinkles } from '@vanilla-extract/sprinkles'

const colors = {
export const colors = {
black: '#000',
white: '#fff',
primary: '#0075F9',
aqua: '#00E3E3',
darkModeBlack: '#181C20',
lightModeBlack: '#2B2B2B',
separator: '#dddddd',
}

const colorProperties = defineProperties({
Expand Down

0 comments on commit aba8fd4

Please sign in to comment.