Skip to content

Commit

Permalink
fix: make theme orange
Browse files Browse the repository at this point in the history
  • Loading branch information
jrea committed Nov 30, 2022
1 parent 97b88a3 commit 329ff3e
Show file tree
Hide file tree
Showing 5 changed files with 61 additions and 61 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,8 @@ export default function AggregateBarChart(
datasets: [
{
data,
backgroundColor: 'rgb(111 226 255)',
borderColor: 'rgb(77, 158, 178)',
borderColor: '#ffb96a',
backgroundColor: '#ff9c3f',
borderSkipped: true,
barPercentage: 0.9,
...dataset,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ export default function AggregateLineChart(
datasets: [
{
data,
backgroundColor: 'rgb(111 226 255)',
borderColor: 'rgb(77, 158, 178)',
borderColor: '#ffb96a',
backgroundColor: '#ff9c3f',
pointRadius: 0,
borderWidth: 6,
cubicInterpolationMode: 'monotone',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@ export default function FilterBarChart(
return {
label: metricName,
data: [datum],
backgroundColor: 'rgb(111 226 255)',
borderColor: 'rgb(77, 158, 178)',
borderColor: '#ffb96a',
backgroundColor: '#ff9c3f',
borderSkipped: true,
barPercentage: 0.9,
grouped: true,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ export default function FilterLineChart(
datasets: [
{
data,
borderColor: 'rgb(111 226 255)',
backgroundColor: 'rgb(77, 158, 178)',
borderColor: '#ffb96a',
backgroundColor: '#ff9c3f',
pointRadius: 0,
borderWidth: 6,
cubicInterpolationMode: 'monotone',
Expand Down
106 changes: 53 additions & 53 deletions packages/react/src/context/themeJoiner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ import {
Shadows,
ZIndex,
} from '@mui/material/styles';
import colors from '@mui/joy/colors';
import {
extendTheme as extendJoyTheme,
Theme as JoyTheme,
Expand Down Expand Up @@ -71,81 +70,82 @@ declare module '@mui/material/styles' {
}
}

const palette = {
primary: { main: '#6fe2ff' },
secondary: {
main: '#ffb96a',
},
neutral: {
main: '#d8d3ff',
dark: '#aea4fe',
contrastText: '#fff',
},
background: {
paper: '#383742',
default: '#0f0f0e',
},
};

// eslint-disable-next-line @typescript-eslint/ban-ts-comment
//@ts-ignore
export const muiTheme = extendMuiTheme({
cssVarPrefix: 'joy',
colorSchemes: {
light: {
palette,
},
dark: {
palette,
},
},
});

// remove things that break
// if the theme is being overridden, these need added to the custom theme
const joyTheme = extendJoyTheme({
cssVarPrefix: 'joy',
colorSchemes: {
light: {
palette: {
primary: {
main: colors.blue[500],
},
grey: colors.grey,
error: {
main: colors.red[500],
'50': '#fff3e4',
'100': '#ffe1bc',
'200': '#ffcd92',
'300': '#ffb96a',
'400': '#feaa51',
'500': '#ff9c3f',
'600': '#f9913d',
'700': '#f28239',
'800': '#eb7435',
'900': '#e05c2e',
},
info: {
main: colors.purple[500],
},
success: {
main: colors.green[500],
},
warning: {
main: colors.yellow[200],
},
common: {
white: '#FFF',
black: '#09090D',
},
divider: colors.grey[800],
text: {
primary: colors.grey[800],
secondary: colors.grey[600],
tertiary: 'rgba(0 0 0 / 0.56)',
},
},
},
dark: {
palette: {
primary: {
main: colors.blue[600],
},
grey: colors.grey,
error: {
main: colors.red[600],
},
info: {
main: colors.purple[600],
},
success: {
main: colors.green[600],
},
warning: {
main: colors.yellow[300],
'50': '#fff3e4',
'100': '#ffe1bc',
'200': '#ffcd92',
'300': '#ffb96a',
'400': '#feaa51',
'500': '#ff9c3f',
'600': '#f9913d',
'700': '#f28239',
'800': '#eb7435',
'900': '#e05c2e',
},
common: {
white: '#FFF',
black: '#09090D',
},
divider: colors.grey[200],
text: {
primary: colors.grey[100],
secondary: colors.grey[300],
tertiary: 'rgba(255 255 255 / 0.5)',
},
},
},
},
});

// remove things that break
// if the theme is being overridden, these need added to the custom theme
const fixer = extendJoyTheme({
colorSchemes: {
dark: { palette: { divider: colors.grey[200], Skeleton: {} } },
light: { palette: { divider: colors.grey[800], Skeleton: {} } },
},
});

const theme = deepmerge(muiTheme, fixer);
const theme = deepmerge(joyTheme, muiTheme);

export default theme;

2 comments on commit 329ff3e

@vercel
Copy link

@vercel vercel bot commented on 329ff3e Nov 30, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

nile-js – ./

nile-js.vercel.app
nile-js-theniledev.vercel.app
nile-js-git-master-theniledev.vercel.app

@vercel
Copy link

@vercel vercel bot commented on 329ff3e Nov 30, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.