match icons for S3 providers

Signed-off-by: FTCHD <144691102+FTCHD@users.noreply.github.com>
This commit is contained in:
FTCHD
2025-09-15 18:29:18 +02:00
parent 2c502b34c1
commit 71aaef6338
61 changed files with 51 additions and 9 deletions
+6 -1
View File
@@ -100,7 +100,10 @@ export async function getRemote(remote: string) {
method: 'POST',
headers: getAuthHeader(),
}).then(
(res) => res.json() as Promise<{ type: string } & Record<string, string | number | boolean>>
(res) =>
res.json() as Promise<
{ type: string; provider?: string } & Record<string, string | number | boolean>
>
)
// console.log(JSON.stringify(r, null, 2))
@@ -138,6 +141,8 @@ export async function createRemote(
options.set('type', type)
options.set('parameters', JSON.stringify(parameters))
console.log('[createRemote] params', options.toString())
await fetch(`http://localhost:5572/config/create?${options.toString()}`, {
method: 'POST',
headers: getAuthHeader(),

Before

Width:  |  Height:  |  Size: 149 KiB

After

Width:  |  Height:  |  Size: 149 KiB

Before

Width:  |  Height:  |  Size: 149 KiB

After

Width:  |  Height:  |  Size: 149 KiB

Before

Width:  |  Height:  |  Size: 20 KiB

After

Width:  |  Height:  |  Size: 20 KiB

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 11 KiB

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 12 KiB

Before

Width:  |  Height:  |  Size: 8.1 KiB

After

Width:  |  Height:  |  Size: 8.1 KiB

Before

Width:  |  Height:  |  Size: 164 KiB

After

Width:  |  Height:  |  Size: 164 KiB

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 12 KiB

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

Before

Width:  |  Height:  |  Size: 6.5 KiB

After

Width:  |  Height:  |  Size: 6.5 KiB

Before

Width:  |  Height:  |  Size: 15 KiB

After

Width:  |  Height:  |  Size: 15 KiB

Before

Width:  |  Height:  |  Size: 8.6 KiB

After

Width:  |  Height:  |  Size: 8.6 KiB

Before

Width:  |  Height:  |  Size: 8.0 KiB

After

Width:  |  Height:  |  Size: 8.0 KiB

Before

Width:  |  Height:  |  Size: 138 KiB

After

Width:  |  Height:  |  Size: 138 KiB

Before

Width:  |  Height:  |  Size: 8.6 KiB

After

Width:  |  Height:  |  Size: 8.6 KiB

Before

Width:  |  Height:  |  Size: 69 KiB

After

Width:  |  Height:  |  Size: 69 KiB

Before

Width:  |  Height:  |  Size: 4.5 KiB

After

Width:  |  Height:  |  Size: 4.5 KiB

Before

Width:  |  Height:  |  Size: 94 KiB

After

Width:  |  Height:  |  Size: 94 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 58 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 168 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 124 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 25 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 68 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 42 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 102 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 111 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 97 KiB

+20 -3
View File
@@ -98,7 +98,19 @@ export default function RemoteCreateDrawer({
}}
>
{(item) => (
<AutocompleteItem key={item.Value} textValue={item.Value}>
<AutocompleteItem
key={item.Value}
textValue={item.Value}
startContent={
option.Name === 'provider' && (
<img
src={`/icons/providers/${item.Value}.png`}
className="object-contain w-4 h-4"
alt={item.Value}
/>
)
}
>
{item.Help || item.Value}
</AutocompleteItem>
)}
@@ -183,6 +195,8 @@ export default function RemoteCreateDrawer({
await createRemote(name, type, parameters)
addRemote(name)
onClose()
setConfig({})
setShowMoreOptions(false)
await triggerTrayRebuild()
} catch (error) {
console.error('Failed to create remote:', error)
@@ -263,7 +277,7 @@ export default function RemoteCreateDrawer({
key={backend.Name}
startContent={
<img
src={`/icons/${backend.Prefix}.png`}
src={`/icons/backends/${backend.Prefix}.png`}
className="object-contain w-8 h-8"
alt={backend.Name}
/>
@@ -271,7 +285,10 @@ export default function RemoteCreateDrawer({
>
{backend.Description.includes('Compliant')
? `${backend.Description.split('Compliant')[0]} Compliant`
: backend.Description || backend.Name}
: backend.Description?.replace(
' (this is not Google Drive)',
''
) || backend.Name}
</SelectItem>
))}
</Select>
+18 -3
View File
@@ -92,7 +92,19 @@ export default function RemoteEditDrawer({
description={option.Help.split('\n').slice(1).join('\n')}
>
{(item) => (
<AutocompleteItem key={item.Value} textValue={item.Value}>
<AutocompleteItem
key={item.Value}
textValue={item.Value}
startContent={
option.Name === 'provider' && (
<img
src={`/icons/providers/${item.Value}.png`}
className="object-contain w-4 h-4"
alt={item.Value}
/>
)
}
>
{item.Help || item.Value}
</AutocompleteItem>
)}
@@ -208,7 +220,7 @@ export default function RemoteEditDrawer({
key={backend.Name}
startContent={
<img
src={`/icons/${backend.Prefix}.png`}
src={`/icons/backends/${backend.Prefix}.png`}
className="object-contain w-8 h-8"
alt={backend.Name}
/>
@@ -216,7 +228,10 @@ export default function RemoteEditDrawer({
>
{backend.Description.includes('Compliant')
? `${backend.Description.split('Compliant')[0]} Compliant`
: backend.Description || backend.Name}
: backend.Description?.replace(
' (this is not Google Drive)',
''
) || backend.Name}
</SelectItem>
))}
</Select>
+7 -2
View File
@@ -652,7 +652,7 @@ function LicenseSection() {
autoComplete="off"
autoCorrect="off"
spellCheck="false"
endContent={licenseValid && <CheckIcon className="w-5 h-5 text-green-500" />}
endContent={licenseValid && <CheckIcon className="w-5 h-5 text-success" />}
data-focus-visible="false"
fullWidth={true}
/>
@@ -705,6 +705,7 @@ function LicenseSection() {
isLoading={isRevoking}
color="danger"
variant="ghost"
size="lg"
onPress={async () => {
// usePersistedStore.setState({
// licenseKey: undefined,
@@ -914,14 +915,18 @@ function RemoteCard({
onDeletePress: () => void
}) {
const [type, setType] = useState<string | null>(null)
const [provider, setProvider] = useState<string | null>(null)
const imageUrl = type ? `/icons/${type}.png` : undefined
const imageUrl = provider ? `/icons/providers/${provider}.png` : `/icons/backends/${type}.png`
useEffect(() => {
const loadRemoteConfig = async () => {
try {
const remoteInfo = await getRemote(remote)
setType(remoteInfo.type)
if (remoteInfo.provider) {
setProvider(remoteInfo.provider)
}
} catch (error) {
console.error('[RemoteCard] Failed to load remote config:', error)
}