Skip to content

Commit 4f3e2c6

Browse files
author
Lasse Boisen Andersen
authored
Merge branch 'main' into bump-browser-based-sdks-to-3.1.0
2 parents 4a6fa56 + e42c190 commit 4f3e2c6

4 files changed

Lines changed: 33 additions & 1 deletion

File tree

packages/browser-sdk/src/toolbar/Features.css

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,15 @@
6969
text-overflow: ellipsis;
7070
width: auto;
7171
padding: 6px 6px 6px 0;
72+
display: flex;
73+
align-items: center;
74+
gap: 8px;
75+
76+
.feature-icon {
77+
height: 15px;
78+
width: 15px;
79+
color: var(--dimmed-color);
80+
}
7281
}
7382

7483
.feature-link {

packages/browser-sdk/src/toolbar/Features.tsx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
import { h } from "preact";
22
import { useEffect, useState } from "preact/hooks";
33

4+
import { Feature } from "../ui/icons/Feature";
5+
46
import { Switch } from "./Switch";
57
import { FeatureItem } from "./Toolbar";
68

@@ -79,6 +81,7 @@ function FeatureRow({
7981
style={{ "--i": index }}
8082
>
8183
<td class="feature-name-cell">
84+
<Feature class="feature-icon" />
8285
<a
8386
class="feature-link"
8487
href={`${appBaseUrl}/envs/current/features/by-key/${feature.key}`}

packages/browser-sdk/src/toolbar/Toolbar.css

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@
5959
--bg-color: hsla(230, 9%, 8%, 0.85);
6060
--bg-light-color: hsla(230, 9%, 6%, 0.85);
6161
--border-color: hsla(0, 0%, 100%, 0.1);
62+
--dimmed-color: hsla(230, 9%, 40%, 1);
6263
--bg-blur: 3px;
6364

6465
--logo-color: white;
@@ -97,7 +98,7 @@
9798
inset 0px 1px rgba(255, 255, 255, 0.1);
9899
border-radius: 7px;
99100
z-index: 999999;
100-
min-width: 200px;
101+
min-width: 220px;
101102
padding: 0;
102103

103104
--visible-features: 15;
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
import { FunctionComponent, h } from "preact";
2+
3+
export const Feature: FunctionComponent<h.JSX.SVGAttributes<SVGSVGElement>> = (
4+
props,
5+
) => (
6+
<svg
7+
fill="none"
8+
height="24"
9+
viewBox="0 0 24 24"
10+
width="24"
11+
xmlns="http://www.w3.org/2000/svg"
12+
{...props}
13+
>
14+
<path
15+
d="M10.7474 1.72518C11.5222 1.2766 12.4778 1.27661 13.2526 1.72518L20.2526 5.77782C21.0246 6.22479 21.5 7.04929 21.5 7.94138V16.0586C21.5 16.9507 21.0246 17.7752 20.2526 18.2222L13.2526 22.2748C12.4778 22.7234 11.5222 22.7234 10.7474 22.2748L3.74741 18.2222C2.97537 17.7752 2.5 16.9507 2.5 16.0586V7.94138C2.5 7.04929 2.97537 6.22479 3.74741 5.77782L10.7474 1.72518ZM5.49388 7.0777L12.0001 10.8444L18.5062 7.07774L12 3.311L5.49388 7.0777ZM4.5 8.81329V16.3469L11.0001 20.1101V12.5765L4.5 8.81329ZM13.0001 20.11L19.5 16.3469V8.81337L13.0001 12.5765V20.11Z"
16+
fill="currentColor"
17+
/>
18+
</svg>
19+
);

0 commit comments

Comments
 (0)