@seamapi/react 1.24.0 → 1.25.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/elements.js +3985 -3819
- package/dist/elements.js.map +1 -1
- package/dist/index.css +157 -45
- package/dist/index.css.map +1 -1
- package/dist/index.min.css +1 -1
- package/dist/index.min.css.map +1 -1
- package/lib/seam/components/SupportedDeviceTable/HiddenDevicesOverlay.d.ts +5 -0
- package/lib/seam/components/SupportedDeviceTable/HiddenDevicesOverlay.js +8 -0
- package/lib/seam/components/SupportedDeviceTable/HiddenDevicesOverlay.js.map +1 -0
- package/lib/seam/components/SupportedDeviceTable/ShowAllDevicesButton.d.ts +8 -0
- package/lib/seam/components/SupportedDeviceTable/ShowAllDevicesButton.js +14 -0
- package/lib/seam/components/SupportedDeviceTable/ShowAllDevicesButton.js.map +1 -0
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceBrandSection.d.ts +7 -0
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceBrandSection.js +45 -0
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceBrandSection.js.map +1 -0
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceContent.d.ts +2 -1
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceContent.js +36 -11
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceContent.js.map +1 -1
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceContentRows.d.ts +7 -0
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceContentRows.js +12 -0
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceContentRows.js.map +1 -0
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceFilterArea.d.ts +2 -1
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceFilterArea.js +12 -4
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceFilterArea.js.map +1 -1
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceFilterResultRowProps.d.ts +7 -0
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceFilterResultRowProps.js +12 -0
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceFilterResultRowProps.js.map +1 -0
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceRow.d.ts +4 -0
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceRow.js +19 -5
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceRow.js.map +1 -1
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceTable.d.ts +2 -1
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceTable.js +3 -3
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceTable.js.map +1 -1
- package/lib/seam/components/SupportedDeviceTable/use-device-provider.d.ts +2 -0
- package/lib/seam/components/SupportedDeviceTable/use-device-provider.js +15 -0
- package/lib/seam/components/SupportedDeviceTable/use-device-provider.js.map +1 -0
- package/lib/seam/components/SupportedDeviceTable/use-filtered-device-models.d.ts +5 -1
- package/lib/seam/components/SupportedDeviceTable/use-filtered-device-models.js +9 -2
- package/lib/seam/components/SupportedDeviceTable/use-filtered-device-models.js.map +1 -1
- package/lib/seam/devices/use-device-providers.d.ts +5 -0
- package/lib/seam/devices/use-device-providers.js +17 -0
- package/lib/seam/devices/use-device-providers.js.map +1 -0
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/package.json +2 -2
- package/src/lib/seam/components/SupportedDeviceTable/HiddenDevicesOverlay.tsx +11 -0
- package/src/lib/seam/components/SupportedDeviceTable/ShowAllDevicesButton.tsx +32 -0
- package/src/lib/seam/components/SupportedDeviceTable/SupportedDeviceBrandSection.tsx +96 -0
- package/src/lib/seam/components/SupportedDeviceTable/SupportedDeviceContent.tsx +62 -16
- package/src/lib/seam/components/SupportedDeviceTable/SupportedDeviceContentRows.tsx +27 -0
- package/src/lib/seam/components/SupportedDeviceTable/SupportedDeviceFilterArea.tsx +22 -3
- package/src/lib/seam/components/SupportedDeviceTable/SupportedDeviceFilterResultRowProps.tsx +49 -0
- package/src/lib/seam/components/SupportedDeviceTable/SupportedDeviceRow.tsx +52 -20
- package/src/lib/seam/components/SupportedDeviceTable/SupportedDeviceTable.element.ts +1 -0
- package/src/lib/seam/components/SupportedDeviceTable/SupportedDeviceTable.tsx +4 -0
- package/src/lib/seam/components/SupportedDeviceTable/use-device-provider.ts +22 -0
- package/src/lib/seam/components/SupportedDeviceTable/use-filtered-device-models.ts +21 -4
- package/src/lib/seam/devices/use-device-providers.ts +25 -0
- package/src/lib/version.ts +1 -1
- package/src/styles/_access-code-details.scss +1 -1
- package/src/styles/_buttons.scss +3 -3
- package/src/styles/_colors.scss +6 -2
- package/src/styles/_menus.scss +1 -1
- package/src/styles/_supported-device-table.scss +192 -52
- package/src/styles/_tables.scss +1 -1
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceHeader.d.ts +0 -2
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceHeader.js +0 -12
- package/lib/seam/components/SupportedDeviceTable/SupportedDeviceHeader.js.map +0 -1
- package/src/lib/seam/components/SupportedDeviceTable/SupportedDeviceHeader.tsx +0 -22
|
@@ -14,6 +14,7 @@ export interface SupportedDeviceFilterAreaProps {
|
|
|
14
14
|
setFilterValue: (filter: string) => void
|
|
15
15
|
filters: DeviceModelFilters
|
|
16
16
|
setFilters: Dispatch<SetStateAction<DeviceModelFilters>>
|
|
17
|
+
brands: string[]
|
|
17
18
|
}
|
|
18
19
|
|
|
19
20
|
export function SupportedDeviceFilterArea({
|
|
@@ -21,13 +22,14 @@ export function SupportedDeviceFilterArea({
|
|
|
21
22
|
setFilterValue,
|
|
22
23
|
filters,
|
|
23
24
|
setFilters,
|
|
25
|
+
brands,
|
|
24
26
|
}: SupportedDeviceFilterAreaProps): JSX.Element {
|
|
25
27
|
const appliedFiltersCount = Object.values(filters).filter(
|
|
26
28
|
(v) => v != null && v !== false
|
|
27
29
|
).length
|
|
28
30
|
|
|
29
31
|
const filterProperty = 'brand'
|
|
30
|
-
const availableProperties = useAvailableProperties(filterProperty)
|
|
32
|
+
const availableProperties = useAvailableProperties(filterProperty, { brands })
|
|
31
33
|
|
|
32
34
|
const resetFilter = (filterType: keyof DeviceModelFilters): void => {
|
|
33
35
|
setFilters((filters) => ({
|
|
@@ -116,12 +118,29 @@ export function SupportedDeviceFilterArea({
|
|
|
116
118
|
)
|
|
117
119
|
}
|
|
118
120
|
|
|
119
|
-
const useAvailableProperties = (
|
|
121
|
+
const useAvailableProperties = (
|
|
122
|
+
property: keyof DeviceModel,
|
|
123
|
+
options: {
|
|
124
|
+
brands: string[]
|
|
125
|
+
}
|
|
126
|
+
): string[] => {
|
|
120
127
|
const { deviceModels } = useDeviceModels()
|
|
121
128
|
if (deviceModels == null) return []
|
|
122
129
|
const properties = new Set<string>()
|
|
123
130
|
for (const deviceModel of deviceModels) {
|
|
124
|
-
|
|
131
|
+
const value = deviceModel[property]
|
|
132
|
+
|
|
133
|
+
// If we're only looking at a subset of brands, such as ["yale", "august"], then we
|
|
134
|
+
// don't want to show other brands in the filter.
|
|
135
|
+
if (
|
|
136
|
+
property === 'brand' &&
|
|
137
|
+
options.brands.length > 0 &&
|
|
138
|
+
!options.brands.includes(value)
|
|
139
|
+
) {
|
|
140
|
+
continue
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
properties.add(capitalize(value))
|
|
125
144
|
}
|
|
126
145
|
return Array.from(properties)
|
|
127
146
|
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import type { DeviceModel } from 'seamapi'
|
|
2
|
+
|
|
3
|
+
import {
|
|
4
|
+
connectionTypeNames,
|
|
5
|
+
ImageColumn,
|
|
6
|
+
StatusColumn,
|
|
7
|
+
} from 'lib/seam/components/SupportedDeviceTable/SupportedDeviceRow.js'
|
|
8
|
+
import { useDeviceProvider } from 'lib/seam/components/SupportedDeviceTable/use-device-provider.js'
|
|
9
|
+
import { DotDivider } from 'lib/ui/layout/DotDivider.js'
|
|
10
|
+
|
|
11
|
+
export interface SupportedDeviceFilterResultRowProps {
|
|
12
|
+
deviceModel: DeviceModel
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export function SupportedDeviceFilterResultRow({
|
|
16
|
+
deviceModel,
|
|
17
|
+
}: SupportedDeviceFilterResultRowProps): JSX.Element {
|
|
18
|
+
return (
|
|
19
|
+
<div className='seam-row filter-result-row'>
|
|
20
|
+
<ImageColumn deviceModel={deviceModel} />
|
|
21
|
+
<ModelColumn deviceModel={deviceModel} />
|
|
22
|
+
<StatusColumn deviceModel={deviceModel} />
|
|
23
|
+
</div>
|
|
24
|
+
)
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export function ModelColumn({
|
|
28
|
+
deviceModel,
|
|
29
|
+
}: SupportedDeviceFilterResultRowProps) {
|
|
30
|
+
const deviceProvider = useDeviceProvider(deviceModel.brand)
|
|
31
|
+
|
|
32
|
+
return (
|
|
33
|
+
<div className='seam-col seam-model-col'>
|
|
34
|
+
<div className='seam-model-name'>
|
|
35
|
+
<img
|
|
36
|
+
src={deviceProvider.image_url}
|
|
37
|
+
alt={deviceModel.brand}
|
|
38
|
+
className='seam-brand-image'
|
|
39
|
+
/>{' '}
|
|
40
|
+
{deviceModel.model_name}
|
|
41
|
+
</div>
|
|
42
|
+
<div className='seam-model-id'>
|
|
43
|
+
{deviceModel.manufacturer_model_id}
|
|
44
|
+
<DotDivider />
|
|
45
|
+
{connectionTypeNames[deviceModel.connection_type]}
|
|
46
|
+
</div>
|
|
47
|
+
</div>
|
|
48
|
+
)
|
|
49
|
+
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import classNames from 'classnames'
|
|
2
2
|
import type { DeviceModel } from 'seamapi'
|
|
3
3
|
|
|
4
|
-
import {
|
|
4
|
+
import { DotDivider } from 'lib/ui/layout/DotDivider.js'
|
|
5
5
|
|
|
6
6
|
export interface SupportedDeviceRowProps {
|
|
7
7
|
deviceModel: DeviceModel
|
|
@@ -10,37 +10,69 @@ export interface SupportedDeviceRowProps {
|
|
|
10
10
|
export function SupportedDeviceRow({
|
|
11
11
|
deviceModel,
|
|
12
12
|
}: SupportedDeviceRowProps): JSX.Element {
|
|
13
|
-
const statusColor = supportLevelColors[deviceModel.support_level] ?? 'gray'
|
|
14
13
|
return (
|
|
15
|
-
<
|
|
16
|
-
<
|
|
14
|
+
<div className='seam-row'>
|
|
15
|
+
<ImageColumn deviceModel={deviceModel} />
|
|
16
|
+
<ModelColumn deviceModel={deviceModel} />
|
|
17
|
+
<StatusColumn deviceModel={deviceModel} />
|
|
18
|
+
</div>
|
|
19
|
+
)
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export function ImageColumn({ deviceModel }: SupportedDeviceRowProps) {
|
|
23
|
+
return (
|
|
24
|
+
<div className='seam-col seam-device-image-col'>
|
|
25
|
+
<div className='seam-image-box'>
|
|
17
26
|
<img width={40} src={deviceModel.icon_url} />
|
|
18
|
-
</
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
27
|
+
</div>
|
|
28
|
+
</div>
|
|
29
|
+
)
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export function ModelColumn({ deviceModel }: SupportedDeviceRowProps) {
|
|
33
|
+
return (
|
|
34
|
+
<div className='seam-col seam-model-col'>
|
|
35
|
+
<div className='seam-model-name'>{deviceModel.model_name}</div>
|
|
36
|
+
<div className='seam-model-id'>
|
|
37
|
+
{deviceModel.manufacturer_model_id}
|
|
38
|
+
<DotDivider />
|
|
39
|
+
{connectionTypeNames[deviceModel.connection_type]}
|
|
40
|
+
</div>
|
|
41
|
+
</div>
|
|
42
|
+
)
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export function StatusColumn({ deviceModel }: SupportedDeviceRowProps) {
|
|
46
|
+
const statusColor = supportLevelColors[deviceModel.support_level] ?? 'unknown'
|
|
47
|
+
|
|
48
|
+
return (
|
|
49
|
+
<div className='seam-col seam-status-col'>
|
|
50
|
+
<div className={classNames('seam-status-pill', `status-${statusColor}`)}>
|
|
51
|
+
<span>{status[deviceModel.support_level]}</span>
|
|
52
|
+
</div>
|
|
53
|
+
</div>
|
|
31
54
|
)
|
|
32
55
|
}
|
|
33
56
|
|
|
34
57
|
const supportLevelColors: Record<
|
|
35
58
|
DeviceModel['support_level'],
|
|
36
|
-
'green' | 'blue' | '
|
|
59
|
+
'green' | 'blue' | 'unknown'
|
|
37
60
|
> = {
|
|
38
61
|
live: 'green',
|
|
39
62
|
beta: 'blue',
|
|
40
|
-
unsupported: '
|
|
63
|
+
unsupported: 'unknown',
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
const status: Record<DeviceModel['support_level'], string> = {
|
|
67
|
+
live: 'LIVE',
|
|
68
|
+
beta: 'BETA',
|
|
69
|
+
unsupported: 'Inquire',
|
|
41
70
|
}
|
|
42
71
|
|
|
43
|
-
const connectionTypeNames: Record<
|
|
72
|
+
export const connectionTypeNames: Record<
|
|
73
|
+
DeviceModel['connection_type'],
|
|
74
|
+
string
|
|
75
|
+
> = {
|
|
44
76
|
wifi: 'Wifi',
|
|
45
77
|
zwave: 'Z-Wave',
|
|
46
78
|
zigbee: 'Zigbee',
|
|
@@ -11,12 +11,14 @@ export interface SupportedDeviceTableProps {
|
|
|
11
11
|
* @deprecated Use disableFilter.
|
|
12
12
|
*/
|
|
13
13
|
cannotFilter?: boolean
|
|
14
|
+
brands?: string[]
|
|
14
15
|
className?: string
|
|
15
16
|
}
|
|
16
17
|
|
|
17
18
|
export function SupportedDeviceTable({
|
|
18
19
|
disableFilter = false,
|
|
19
20
|
cannotFilter,
|
|
21
|
+
brands = [],
|
|
20
22
|
className,
|
|
21
23
|
}: SupportedDeviceTableProps = {}): JSX.Element {
|
|
22
24
|
const [filterValue, setFilterValue] = useState('')
|
|
@@ -41,6 +43,7 @@ export function SupportedDeviceTable({
|
|
|
41
43
|
setFilterValue={setFilterValue}
|
|
42
44
|
filters={filters}
|
|
43
45
|
setFilters={setFilters}
|
|
46
|
+
brands={brands}
|
|
44
47
|
/>
|
|
45
48
|
)}
|
|
46
49
|
<SupportedDeviceContent
|
|
@@ -49,6 +52,7 @@ export function SupportedDeviceTable({
|
|
|
49
52
|
}}
|
|
50
53
|
filterValue={filterValue}
|
|
51
54
|
filters={filters}
|
|
55
|
+
brands={brands}
|
|
52
56
|
/>
|
|
53
57
|
</div>
|
|
54
58
|
)
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { DeviceProvider } from 'seamapi'
|
|
2
|
+
|
|
3
|
+
import { useDeviceProviders } from 'lib/seam/devices/use-device-providers.js'
|
|
4
|
+
|
|
5
|
+
export function useDeviceProvider(brand: string): DeviceProvider {
|
|
6
|
+
const { deviceProviders } = useDeviceProviders()
|
|
7
|
+
|
|
8
|
+
const definedProvider = deviceProviders?.find(
|
|
9
|
+
(provider) => provider.device_provider_name === brand
|
|
10
|
+
)
|
|
11
|
+
|
|
12
|
+
if (definedProvider != null) {
|
|
13
|
+
return definedProvider
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
return {
|
|
17
|
+
device_provider_name: 'unknown',
|
|
18
|
+
display_name: 'Unknown',
|
|
19
|
+
image_url: `https://connect.getseam.com/assets/images/logos/seam.png`,
|
|
20
|
+
provider_categories: [],
|
|
21
|
+
}
|
|
22
|
+
}
|
|
@@ -9,10 +9,15 @@ export interface DeviceModelFilters {
|
|
|
9
9
|
brand: string | null
|
|
10
10
|
}
|
|
11
11
|
|
|
12
|
-
export const useFilteredDeviceModels = (
|
|
13
|
-
filterValue
|
|
12
|
+
export const useFilteredDeviceModels = ({
|
|
13
|
+
filterValue,
|
|
14
|
+
filters,
|
|
15
|
+
brands,
|
|
16
|
+
}: {
|
|
17
|
+
filterValue: string
|
|
14
18
|
filters: DeviceModelFilters
|
|
15
|
-
|
|
19
|
+
brands: string[]
|
|
20
|
+
}): ReturnType<typeof useDeviceModels> => {
|
|
16
21
|
const params: UseDeviceModelsParams = {}
|
|
17
22
|
|
|
18
23
|
if (filterValue.trim() !== '') {
|
|
@@ -31,5 +36,17 @@ export const useFilteredDeviceModels = (
|
|
|
31
36
|
params.brand = filters.brand
|
|
32
37
|
}
|
|
33
38
|
|
|
34
|
-
|
|
39
|
+
const query = useDeviceModels(params)
|
|
40
|
+
|
|
41
|
+
if (brands.length === 0) {
|
|
42
|
+
return query
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
// If the user only wants models for a collection of brands, such as ["yale", "august"], then
|
|
46
|
+
// we'll filter everything else out here.
|
|
47
|
+
const onlySpecificBrands = query.deviceModels?.filter((deviceModel) =>
|
|
48
|
+
brands.includes(deviceModel.brand)
|
|
49
|
+
)
|
|
50
|
+
|
|
51
|
+
return { ...query, deviceModels: onlySpecificBrands }
|
|
35
52
|
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { useQuery } from '@tanstack/react-query'
|
|
2
|
+
import type { DeviceProvider } from 'seamapi'
|
|
3
|
+
|
|
4
|
+
import { useSeamClient } from 'lib/seam/use-seam-client.js'
|
|
5
|
+
|
|
6
|
+
export function useDeviceProviders(): {
|
|
7
|
+
deviceProviders: DeviceProvider[] | undefined
|
|
8
|
+
isLoading: boolean
|
|
9
|
+
} {
|
|
10
|
+
const { client } = useSeamClient()
|
|
11
|
+
|
|
12
|
+
const { data, isLoading } = useQuery({
|
|
13
|
+
queryFn: async () => {
|
|
14
|
+
if (client == null) {
|
|
15
|
+
return []
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
return await client?.devices.listDeviceProviders({})
|
|
19
|
+
},
|
|
20
|
+
queryKey: ['devices', 'list_device_providers'],
|
|
21
|
+
enabled: client != null,
|
|
22
|
+
})
|
|
23
|
+
|
|
24
|
+
return { deviceProviders: data, isLoading }
|
|
25
|
+
}
|
package/src/lib/version.ts
CHANGED
package/src/styles/_buttons.scss
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
border-radius: 6px;
|
|
7
7
|
border: 1px solid rgb(0 122 252 / 50%);
|
|
8
8
|
cursor: pointer;
|
|
9
|
-
background:
|
|
9
|
+
background: colors.$white;
|
|
10
10
|
padding: 6px;
|
|
11
11
|
line-height: 0;
|
|
12
12
|
|
|
@@ -62,7 +62,7 @@
|
|
|
62
62
|
@mixin button-variant {
|
|
63
63
|
&.seam-btn-solid {
|
|
64
64
|
background: colors.$primary;
|
|
65
|
-
color:
|
|
65
|
+
color: colors.$white;
|
|
66
66
|
border: 1px solid colors.$primary;
|
|
67
67
|
|
|
68
68
|
&:hover {
|
|
@@ -106,7 +106,7 @@
|
|
|
106
106
|
&:disabled {
|
|
107
107
|
color: colors.$text-gray-2-5;
|
|
108
108
|
border-color: colors.$text-gray-3;
|
|
109
|
-
background:
|
|
109
|
+
background: colors.$white;
|
|
110
110
|
}
|
|
111
111
|
}
|
|
112
112
|
}
|
package/src/styles/_colors.scss
CHANGED
|
@@ -18,10 +18,10 @@ $bg-d: #cbd0d3;
|
|
|
18
18
|
$bg-c: #dde0e2;
|
|
19
19
|
$bg-b: #e9edef;
|
|
20
20
|
$bg-a: #f1f3f4;
|
|
21
|
+
$bg-aa: #fafafa;
|
|
21
22
|
$bg-gray: #ececec;
|
|
22
23
|
$status-red: #e36857;
|
|
23
|
-
$
|
|
24
|
-
$status-green: #27ae60;
|
|
24
|
+
$white: #fff;
|
|
25
25
|
$alert-error-dark: #cb7d7d;
|
|
26
26
|
$alert-error-line: #f1d4d4;
|
|
27
27
|
$alert-error-fill: #ffefef;
|
|
@@ -29,3 +29,7 @@ $alert-warn-dark: #ca8852;
|
|
|
29
29
|
$alert-warn-line: #f8d8be;
|
|
30
30
|
$alert-warn-fill: #fff2e0;
|
|
31
31
|
$item-hover-bg: #f4f6f8;
|
|
32
|
+
$pill-green-bg: rgb(98 232 139 / 30%);
|
|
33
|
+
$pill-green-text: #0d8841;
|
|
34
|
+
$pill-blue-bg: rgb(125 192 241 / 30%);
|
|
35
|
+
$pill-blue-text: #1653b8;
|
package/src/styles/_menus.scss
CHANGED
|
@@ -92,6 +92,102 @@ $row-padding: 8px;
|
|
|
92
92
|
}
|
|
93
93
|
}
|
|
94
94
|
|
|
95
|
+
.seam-brand-section {
|
|
96
|
+
margin-bottom: 32px;
|
|
97
|
+
position: relative;
|
|
98
|
+
|
|
99
|
+
.seam-header {
|
|
100
|
+
display: flex;
|
|
101
|
+
align-items: center;
|
|
102
|
+
height: 64px;
|
|
103
|
+
|
|
104
|
+
.seam-brand-image {
|
|
105
|
+
width: 48px;
|
|
106
|
+
height: 48px;
|
|
107
|
+
padding: 0 8px;
|
|
108
|
+
box-sizing: content-box;
|
|
109
|
+
margin-right: 8px;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
.seam-brand-name {
|
|
113
|
+
font-size: 21px;
|
|
114
|
+
line-height: 132%;
|
|
115
|
+
flex: 1;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.chevron {
|
|
119
|
+
transform: rotate(90deg);
|
|
120
|
+
margin-right: 24px;
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
.show-all-devices-button {
|
|
125
|
+
cursor: pointer;
|
|
126
|
+
background: colors.$white;
|
|
127
|
+
display: flex;
|
|
128
|
+
height: 30px;
|
|
129
|
+
padding: 4px 24px;
|
|
130
|
+
align-items: center;
|
|
131
|
+
gap: 10px;
|
|
132
|
+
font-size: 14px;
|
|
133
|
+
line-height: 115%;
|
|
134
|
+
color: colors.$text-gray-1;
|
|
135
|
+
border-radius: 30px;
|
|
136
|
+
border: 0;
|
|
137
|
+
box-shadow: 0 1px 1px 0 rgb(16 27 37 / 10%),
|
|
138
|
+
0 1px 8px 0 rgb(46 69 82 / 12%);
|
|
139
|
+
position: absolute;
|
|
140
|
+
left: 50%;
|
|
141
|
+
transform: translate(-50%, -47px);
|
|
142
|
+
z-index: 3;
|
|
143
|
+
|
|
144
|
+
svg {
|
|
145
|
+
transform: rotate(90deg);
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
.hidden-devices-overlay {
|
|
150
|
+
background: linear-gradient(
|
|
151
|
+
180deg,
|
|
152
|
+
rgb(255 255 255 / 0%) 10.17%,
|
|
153
|
+
#fff 86.98%
|
|
154
|
+
);
|
|
155
|
+
position: absolute;
|
|
156
|
+
height: 64px;
|
|
157
|
+
width: 100%;
|
|
158
|
+
bottom: 0;
|
|
159
|
+
z-index: 2;
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
&.can-expand {
|
|
163
|
+
.seam-header {
|
|
164
|
+
cursor: pointer;
|
|
165
|
+
|
|
166
|
+
&:hover {
|
|
167
|
+
background: colors.$bg-aa;
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
&.expanded {
|
|
173
|
+
margin-bottom: 96px; // 32px (usual margin) + 64px (empty row)
|
|
174
|
+
|
|
175
|
+
.seam-header {
|
|
176
|
+
.chevron {
|
|
177
|
+
transform: rotate(270deg);
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
.show-all-devices-button {
|
|
182
|
+
transform: translate(-50%, 16px);
|
|
183
|
+
|
|
184
|
+
svg {
|
|
185
|
+
transform: rotate(270deg);
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
|
|
95
191
|
.seam-supported-device-table-content-state-block {
|
|
96
192
|
width: 100%;
|
|
97
193
|
background-color: colors.$bg-a;
|
|
@@ -134,85 +230,129 @@ $row-padding: 8px;
|
|
|
134
230
|
table-layout: auto;
|
|
135
231
|
border-collapse: collapse;
|
|
136
232
|
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
}
|
|
233
|
+
.seam-row {
|
|
234
|
+
height: 64px;
|
|
235
|
+
border-bottom: 1px solid colors.$bg-b;
|
|
236
|
+
display: flex;
|
|
142
237
|
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
background: colors.$bg-a;
|
|
147
|
-
overflow: hidden;
|
|
238
|
+
&:first-child {
|
|
239
|
+
border-top: 1px solid colors.$bg-b;
|
|
240
|
+
}
|
|
148
241
|
|
|
149
|
-
|
|
150
|
-
|
|
242
|
+
.seam-col {
|
|
243
|
+
display: flex;
|
|
244
|
+
padding: 8px;
|
|
151
245
|
}
|
|
152
246
|
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
247
|
+
&.filter-result-row {
|
|
248
|
+
.seam-model-name {
|
|
249
|
+
display: flex;
|
|
250
|
+
align-items: center;
|
|
251
|
+
|
|
252
|
+
.seam-brand-image {
|
|
253
|
+
width: 32px;
|
|
254
|
+
margin-right: 4px;
|
|
255
|
+
}
|
|
256
|
+
}
|
|
158
257
|
}
|
|
159
258
|
}
|
|
160
259
|
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
}
|
|
260
|
+
.seam-status-pill {
|
|
261
|
+
display: inline-flex;
|
|
262
|
+
padding: 4px 8px;
|
|
263
|
+
border-radius: 16px;
|
|
166
264
|
|
|
167
|
-
|
|
168
|
-
|
|
265
|
+
& span {
|
|
266
|
+
font-size: 11px;
|
|
267
|
+
line-height: 134%;
|
|
268
|
+
letter-spacing: 0.55px;
|
|
169
269
|
}
|
|
170
|
-
}
|
|
171
270
|
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
padding-left: $row-padding;
|
|
271
|
+
&.status-green {
|
|
272
|
+
background-color: colors.$pill-green-bg;
|
|
273
|
+
color: colors.$pill-green-text;
|
|
176
274
|
}
|
|
177
275
|
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
276
|
+
&.status-blue {
|
|
277
|
+
background-color: colors.$pill-blue-bg;
|
|
278
|
+
color: colors.$pill-blue-text;
|
|
181
279
|
}
|
|
182
|
-
}
|
|
183
280
|
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
281
|
+
&.status-unknown {
|
|
282
|
+
color: colors.$text-gray-1;
|
|
283
|
+
font-size: 12px;
|
|
284
|
+
line-height: 118%;
|
|
285
|
+
}
|
|
189
286
|
|
|
190
|
-
|
|
191
|
-
color: white;
|
|
192
|
-
font-size: 14px;
|
|
287
|
+
&:not(.status-unknown) {
|
|
193
288
|
font-weight: 600;
|
|
194
|
-
line-height: 1;
|
|
195
289
|
}
|
|
290
|
+
}
|
|
196
291
|
|
|
197
|
-
|
|
198
|
-
|
|
292
|
+
.seam-device-image-col {
|
|
293
|
+
align-items: center;
|
|
294
|
+
|
|
295
|
+
.seam-image-box {
|
|
296
|
+
width: 48px;
|
|
297
|
+
height: 48px;
|
|
298
|
+
|
|
299
|
+
img {
|
|
300
|
+
width: 100%;
|
|
301
|
+
}
|
|
199
302
|
}
|
|
303
|
+
}
|
|
304
|
+
|
|
305
|
+
.seam-model-col {
|
|
306
|
+
flex: 1;
|
|
307
|
+
display: flex;
|
|
308
|
+
flex-direction: column;
|
|
309
|
+
align-items: flex-start;
|
|
310
|
+
justify-content: center;
|
|
311
|
+
gap: 2px;
|
|
200
312
|
|
|
201
|
-
|
|
202
|
-
|
|
313
|
+
.seam-model-name {
|
|
314
|
+
font-size: 14px;
|
|
203
315
|
}
|
|
204
316
|
|
|
205
|
-
|
|
206
|
-
|
|
317
|
+
.seam-model-id {
|
|
318
|
+
color: colors.$text-gray-2;
|
|
319
|
+
font-size: 12px;
|
|
320
|
+
|
|
321
|
+
.seam-dot-divider {
|
|
322
|
+
margin: 0 4px;
|
|
323
|
+
color: colors.$text-gray-3;
|
|
324
|
+
}
|
|
207
325
|
}
|
|
208
326
|
|
|
209
|
-
|
|
210
|
-
|
|
327
|
+
@media only screen and (width >= 450px) {
|
|
328
|
+
.seam-model-name {
|
|
329
|
+
font-size: 16px;
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
.seam-model-id {
|
|
333
|
+
font-size: 14px;
|
|
334
|
+
}
|
|
211
335
|
}
|
|
212
336
|
|
|
213
|
-
|
|
214
|
-
|
|
337
|
+
@media only screen and (width >= 700px) {
|
|
338
|
+
flex-direction: row;
|
|
339
|
+
align-items: center;
|
|
340
|
+
justify-content: flex-start;
|
|
341
|
+
|
|
342
|
+
.seam-model-name {
|
|
343
|
+
flex: 0 0 75%;
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
.seam-model-id {
|
|
347
|
+
font-size: 16px;
|
|
348
|
+
}
|
|
215
349
|
}
|
|
216
350
|
}
|
|
351
|
+
|
|
352
|
+
.seam-status-col {
|
|
353
|
+
width: 70px;
|
|
354
|
+
text-align: center;
|
|
355
|
+
align-items: center;
|
|
356
|
+
}
|
|
217
357
|
}
|
|
218
358
|
}
|