mirror of
https://github.com/umami-software/umami.git
synced 2026-02-13 00:55:37 +01:00
Clean up colors and Selects
This commit is contained in:
parent
9b814aa1ca
commit
895abdbbaf
7 changed files with 5 additions and 21 deletions
|
|
@ -19,7 +19,6 @@ export function AdminLayout({ children }: { children: ReactNode }) {
|
||||||
width="240px"
|
width="240px"
|
||||||
height="100%"
|
height="100%"
|
||||||
border="right"
|
border="right"
|
||||||
backgroundColor
|
|
||||||
marginRight="2"
|
marginRight="2"
|
||||||
padding="3"
|
padding="3"
|
||||||
>
|
>
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,6 @@ export function SettingsLayout({ children }: { children: ReactNode }) {
|
||||||
width="240px"
|
width="240px"
|
||||||
height="100%"
|
height="100%"
|
||||||
border="right"
|
border="right"
|
||||||
backgroundColor={'surface-raised'}
|
|
||||||
marginRight="2"
|
marginRight="2"
|
||||||
padding="3"
|
padding="3"
|
||||||
>
|
>
|
||||||
|
|
|
||||||
|
|
@ -236,7 +236,7 @@ export function Journey({ websiteId, steps, startStep, endStep, view }: JourneyP
|
||||||
<div>{formatLongNumber(nodeCount)}</div>
|
<div>{formatLongNumber(nodeCount)}</div>
|
||||||
</Focusable>
|
</Focusable>
|
||||||
<Tooltip placement="top" offset={20} showArrow>
|
<Tooltip placement="top" offset={20} showArrow>
|
||||||
<Text transform="lowercase" color="ruby">
|
<Text transform="lowercase" color="red-700">
|
||||||
{`${dropped}% ${formatMessage(labels.dropoff)}`}
|
{`${dropped}% ${formatMessage(labels.dropoff)}`}
|
||||||
</Text>
|
</Text>
|
||||||
<Column>
|
<Column>
|
||||||
|
|
|
||||||
|
|
@ -57,10 +57,6 @@ export function FilterRecord({
|
||||||
onChange?.(name, value);
|
onChange?.(name, value);
|
||||||
};
|
};
|
||||||
|
|
||||||
const renderValue = () => {
|
|
||||||
return formatValue(selected, type);
|
|
||||||
};
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Column>
|
<Column>
|
||||||
<Label>{fields.find(f => f.name === name)?.label}</Label>
|
<Label>{fields.find(f => f.name === name)?.label}</Label>
|
||||||
|
|
@ -83,7 +79,6 @@ export function FilterRecord({
|
||||||
value={selected}
|
value={selected}
|
||||||
onChange={handleSelectValue}
|
onChange={handleSelectValue}
|
||||||
searchValue={search}
|
searchValue={search}
|
||||||
renderValue={renderValue}
|
|
||||||
onSearch={handleSearch}
|
onSearch={handleSearch}
|
||||||
isLoading={isLoading}
|
isLoading={isLoading}
|
||||||
listProps={{ renderEmptyState: () => <Empty /> }}
|
listProps={{ renderEmptyState: () => <Empty /> }}
|
||||||
|
|
|
||||||
|
|
@ -62,7 +62,7 @@ export function NavMenu({
|
||||||
{items?.map(({ label, items }, index) => {
|
{items?.map(({ label, items }, index) => {
|
||||||
if (label) {
|
if (label) {
|
||||||
return (
|
return (
|
||||||
<Column key={`${label}${index}`} gap="1" marginBottom="3" minHeight="40px">
|
<Column key={`${label}${index}`} gap="2" marginBottom="3" minHeight="40px">
|
||||||
<Row padding>
|
<Row padding>
|
||||||
<Text weight="bold">{label}</Text>
|
<Text weight="bold">{label}</Text>
|
||||||
</Row>
|
</Row>
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { ListItem, Row, Select, type SelectProps, Text } from '@umami/react-zen';
|
import { ListItem, Select, type SelectProps } from '@umami/react-zen';
|
||||||
import { useMemo, useState } from 'react';
|
import { useMemo, useState } from 'react';
|
||||||
import { Empty } from '@/components/common/Empty';
|
import { Empty } from '@/components/common/Empty';
|
||||||
import { useMessages, useTeamMembersQuery, useUsersQuery } from '@/components/hooks';
|
import { useMessages, useTeamMembersQuery, useUsersQuery } from '@/components/hooks';
|
||||||
|
|
@ -40,14 +40,6 @@ export function UserSelect({
|
||||||
onChange(id);
|
onChange(id);
|
||||||
};
|
};
|
||||||
|
|
||||||
const renderValue = () => {
|
|
||||||
return (
|
|
||||||
<Row maxWidth="160px">
|
|
||||||
<Text truncate>{username}</Text>
|
|
||||||
</Row>
|
|
||||||
);
|
|
||||||
};
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Select
|
<Select
|
||||||
{...props}
|
{...props}
|
||||||
|
|
@ -58,7 +50,6 @@ export function UserSelect({
|
||||||
onSearch={handleSearch}
|
onSearch={handleSearch}
|
||||||
onChange={handleChange}
|
onChange={handleChange}
|
||||||
onOpenChange={handleOpenChange}
|
onOpenChange={handleOpenChange}
|
||||||
renderValue={renderValue}
|
|
||||||
listProps={{
|
listProps={{
|
||||||
renderEmptyState: () => <Empty message={formatMessage(messages.noResultsFound)} />,
|
renderEmptyState: () => <Empty message={formatMessage(messages.noResultsFound)} />,
|
||||||
style: { maxHeight: 'calc(42vh - 65px)' },
|
style: { maxHeight: 'calc(42vh - 65px)' },
|
||||||
|
|
|
||||||
|
|
@ -4,11 +4,11 @@ import { ArrowRight } from '@/components/icons';
|
||||||
|
|
||||||
const STYLES = {
|
const STYLES = {
|
||||||
positive: {
|
positive: {
|
||||||
color: `var(--status-success-text)`,
|
color: `var(--status-success)`,
|
||||||
background: `var(--status-success-bg)`,
|
background: `var(--status-success-bg)`,
|
||||||
},
|
},
|
||||||
negative: {
|
negative: {
|
||||||
color: `var(--status-error-text)`,
|
color: `var(--status-error)`,
|
||||||
background: `var(--status-error-bg)`,
|
background: `var(--status-error-bg)`,
|
||||||
},
|
},
|
||||||
neutral: {
|
neutral: {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue