diff --git a/.changeset/fix-avatar-sm-icon-size.md b/.changeset/fix-avatar-sm-icon-size.md new file mode 100644 index 000000000..51007aae4 --- /dev/null +++ b/.changeset/fix-avatar-sm-icon-size.md @@ -0,0 +1,5 @@ +--- +"@tabler/core": patch +--- + +Fixed the oversized icon in `.avatar-sm` by lowering its `icon-size` in `$avatar-sizes` to `1.25rem`. diff --git a/core/scss/_variables.scss b/core/scss/_variables.scss index 4ed90a11b..ba8722313 100644 --- a/core/scss/_variables.scss +++ b/core/scss/_variables.scss @@ -822,7 +822,7 @@ $avatar-sizes: ( 'sm': ( size: 2rem, font-size: $h5-font-size, - icon-size: 1.5rem, + icon-size: 1.25rem, status-size: 0.5rem, brand-size: 1rem, ), diff --git a/preview/pages/project-analytics.astro b/preview/pages/project-analytics.astro index d5655364a..791853ffc 100644 --- a/preview/pages/project-analytics.astro +++ b/preview/pages/project-analytics.astro @@ -9,15 +9,16 @@ import CardActions from '@ui/CardActions.astro' import CardBody from '@ui/CardBody.astro' import CardHeader from '@ui/CardHeader.astro' import CardTitle from '@ui/CardTitle.astro' -import ChartSparkline from '@ui/ChartSparkline.astro' import NavSegmented from '@ui/NavSegmented.astro' import Progress from '@ui/Progress.astro' +import Subheader from '@ui/Subheader.astro' +import Trending from '@ui/Trending.astro' const stats = [ - { id: 'requests', label: 'Requests', value: '8.61M', delta: '+8.2%', color: 'success', data: '21,24,22,27,29,26,31' }, - { id: 'visitors', label: 'Unique visitors', value: '142K', delta: '+3.1%', color: 'success', data: '12,14,13,15,14,16,17' }, - { id: 'errors', label: 'Error rate', value: '0.42%', delta: '+0.09 pp', color: 'danger', data: '3,2,4,3,5,6,7' }, - { id: 'latency', label: 'p95 latency', value: '212 ms', delta: '-14 ms', color: 'success', data: '9,8,8,7,7,6,6' }, + { id: 'requests', label: 'Requests', value: '8.61M', trend: 8.2, unit: '%', chart: 'new-clients' }, + { id: 'visitors', label: 'Unique visitors', value: '142K', trend: 3.1, unit: '%', chart: 'active-users' }, + { id: 'errors', label: 'Error rate', value: '0.42%', trend: 0.09, unit: ' pp', color: 'red', chart: 'revenue-bg' }, + { id: 'latency', label: 'p95 latency', value: '212 ms', trend: -14, unit: ' ms', color: 'green', chart: 'development-activity' }, ] const routes = [ @@ -50,12 +51,14 @@ const statusCodes = [
-
-
{stat.label}
- {stat.delta} + {stat.label} +
+
{stat.value}
+
+ +
-
{stat.value}
- +
@@ -63,15 +66,15 @@ const statusCodes = [ }
- + Requests - Last 7 days, per hour + Last 90 days, per day - +
@@ -100,8 +103,11 @@ const statusCodes = [
- -
5xx responses per day
+
+ 5xx responses + per day, last 7 days +
+
diff --git a/shared/components/parts/ProjectHeader.astro b/shared/components/parts/ProjectHeader.astro index e4bd4aa6c..69674780c 100644 --- a/shared/components/parts/ProjectHeader.astro +++ b/shared/components/parts/ProjectHeader.astro @@ -38,7 +38,7 @@ const tabs: { key: Tab; label: string; href: string }[] = [
- + {name}
diff --git a/shared/data/charts.json b/shared/data/charts.json index 5c04ff1d9..ba078c6bd 100644 --- a/shared/data/charts.json +++ b/shared/data/charts.json @@ -1001,6 +1001,11 @@ } ] }, + "project-requests": { + "extend": "traffic-zoom", + "toolbar": false, + "start-date": "2026-06-20" + }, "traffic-brush": { "type": "line", "datetime": true, diff --git a/shared/ui/Trending.astro b/shared/ui/Trending.astro index 932009c6c..9f1000ae4 100644 --- a/shared/ui/Trending.astro +++ b/shared/ui/Trending.astro @@ -4,12 +4,14 @@ import Icon from './Icon.astro' interface Props { value: number unit?: string | undefined + /** overrides the sign-based color, e.g. "red" for a rising error rate */ + color?: string | undefined class?: string } -const { value, unit = '%', class: className } = Astro.props +const { value, unit = '%', color, class: className } = Astro.props -const trendingColor = value > 0 ? 'green' : value === 0 ? 'muted' : 'red' +const trendingColor = color ?? (value > 0 ? 'green' : value === 0 ? 'muted' : 'red') const trendingIcon = value > 0 ? 'arrow-up' : value === 0 ? 'minus' : 'arrow-down' const classes = [`text-${trendingColor} d-inline-flex align-items-center lh-1`, className]