feat(wallpaper): extend commands with gallery, delete image, and crop
The plugin now exposes gallery retrieval, image deletion and image crop across Android, desktop and mobile. The Rust core and Android bridge are wired to handle these commands, updating state as needed. - Add gallery, delete_image, and set_image_crop commands - across Android, desktop and mobile. - Update permissions, defaults, and schema to enable new commands.
This commit is contained in:
@@ -8,6 +8,10 @@ h1 { font-size: 34px; letter-spacing: -1.7px; line-height: 1.05; margin: 0 0 6px
|
||||
header p { margin: 0; font-size: 13px; color: #657068; font-weight: 500; }
|
||||
.icon-button { width: 44px; height: 44px; border: 0; border-radius: 50%; background: #edf2eb; color: #31523b; display: grid; place-items: center; }
|
||||
.icon-button svg { width: 21px; }
|
||||
.icon-button:disabled { opacity: .55; }
|
||||
.gallery-header { gap: 14px; }
|
||||
.gallery-header > div { flex: 1; }
|
||||
.gallery-header h1 { font-size: 25px; letter-spacing: -.9px; margin-bottom: 3px; }
|
||||
.content { padding: 0 20px; }
|
||||
.hero { position: relative; height: 294px; margin: 0 0 15px; border-radius: 26px; isolation: isolate; }
|
||||
.hero img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: inherit; z-index: 1; }
|
||||
@@ -38,6 +42,8 @@ h2 { margin: 0; font-size: 21px; letter-spacing: -.6px; }
|
||||
.photo-rail img { width: 100%; height: 100%; object-fit: cover; display: block; }
|
||||
.photo-rail span { position: absolute; left: 7px; top: 7px; width: 23px; height: 23px; background: var(--green); color: white; border-radius: 50%; display: grid; place-items: center; }
|
||||
.photo-rail span svg { width: 14px; }
|
||||
.empty-collection { width: 100%; min-height: 84px; border: 1px dashed #b8c6ba; border-radius: 15px; background: #f1f5ef; color: #667069; display: flex; align-items: center; justify-content: center; gap: 9px; font-size: 13px; font-weight: 650; }
|
||||
.empty-collection svg { width: 20px; color: var(--green); }
|
||||
.hint { margin: 8px 0 12px; text-align: center; font-size: 11px; color: #7a837d; }
|
||||
.settings-list { border-top: 1px solid var(--line); }
|
||||
.settings-page > p { color: #667069; margin: 8px 0 24px; font-size: 14px; }
|
||||
@@ -50,6 +56,23 @@ nav button { border: 0; color: #657068; background: transparent; border-radius:
|
||||
nav button.active { color: var(--green); background: var(--sage); }
|
||||
nav svg { width: 21px; }
|
||||
.snackbar { position: fixed; z-index: 20; left: 50%; transform: translateX(-50%); bottom: 92px; max-width: calc(100% - 40px); background: #26312a; color: white; border: 0; border-radius: 12px; padding: 13px 18px; font-size: 12px; box-shadow: 0 8px 26px rgba(0,0,0,.22); }
|
||||
.gallery-page { padding-bottom: max(24px, env(safe-area-inset-bottom)); }
|
||||
.gallery-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; }
|
||||
.gallery-grid article { position: relative; aspect-ratio: 3 / 4; overflow: hidden; border-radius: 14px; background: #e3e9e2; border: 2px solid transparent; }
|
||||
.gallery-grid article.current { border-color: #73a17c; }
|
||||
.gallery-grid article > img { width: 100%; height: 100%; object-fit: cover; display: block; }
|
||||
.delete-button { position: absolute; top: 7px; right: 7px; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 50%; display: grid; place-items: center; color: white; background: rgba(94, 20, 20, .86); box-shadow: 0 3px 12px rgba(0,0,0,.24); }
|
||||
.delete-button svg { width: 16px; }
|
||||
.delete-button:disabled { opacity: .5; }
|
||||
.current-badge { position: absolute; left: 6px; bottom: 6px; display: flex; align-items: center; gap: 3px; padding: 5px 7px; border-radius: 99px; background: rgba(20, 93, 50, .9); color: white; font-size: 9px; font-weight: 750; }
|
||||
.current-badge svg { width: 11px; height: 11px; }
|
||||
.gallery-empty { min-height: 58vh; padding: 40px 18px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; color: #68736b; }
|
||||
.gallery-empty > svg { width: 48px; height: 48px; padding: 11px; border-radius: 50%; color: var(--green); background: var(--sage); }
|
||||
.gallery-empty h2 { margin-top: 16px; color: #26312a; }
|
||||
.gallery-empty p { max-width: 290px; margin: 8px 0 2px; font-size: 13px; line-height: 1.5; }
|
||||
.gallery-empty .primary { max-width: 260px; }
|
||||
.gallery-status { padding: 28px 0; text-align: center; color: #6d776f; font-size: 13px; }
|
||||
.load-more { width: 100%; height: 48px; margin-top: 18px; border: 1px solid #b9c8bb; border-radius: 15px; color: var(--green); background: white; font-weight: 750; }
|
||||
@media (min-width: 700px) { .app-shell { margin-top: 20px; min-height: calc(100vh - 40px); border-radius: 32px; overflow: hidden; } nav { bottom: 20px; border-radius: 0 0 32px 32px; } }
|
||||
@media (max-height: 740px) { .hero { height: 235px; } }
|
||||
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; } }
|
||||
|
||||
Reference in New Issue
Block a user