feat: added a gallery quick action and fleshed out builtin macros
This commit is contained in:
@@ -29,6 +29,7 @@ value SettingsProjectSection {
|
||||
blog_languages: List<String> -- checkboxes (main language disabled)
|
||||
default_author: String -- text input
|
||||
max_posts_per_page: Integer -- number input (1-500, default 50)
|
||||
image_import_concurrency: Integer -- number input (1-8, default 4)
|
||||
blogmark_category: String -- select from categories
|
||||
}
|
||||
|
||||
@@ -92,6 +93,9 @@ invariant SettingsMCPAgents {
|
||||
config {
|
||||
settings_max_posts_per_page: Integer = 500
|
||||
settings_default_posts_per_page: Integer = 50
|
||||
settings_image_import_concurrency_default: Integer = 4
|
||||
settings_image_import_concurrency_min: Integer = 1
|
||||
settings_image_import_concurrency_max: Integer = 8
|
||||
settings_system_prompt_rows: Integer = 12
|
||||
}
|
||||
|
||||
@@ -131,6 +135,7 @@ surface SettingsViewSurface {
|
||||
-- Section 1: Project Name, Description (textarea 3 rows), Data Path (text + Browse + Reset),
|
||||
-- Public URL, Main Language (select), Blog Languages (checkbox grid, main disabled),
|
||||
-- Default Author, Max Posts Per Page (number 1-500),
|
||||
-- Image Import Concurrency (number 1-8, default 4),
|
||||
-- Blogmark Category (select), Blogmark Bookmarklet (copy button), Save button.
|
||||
|
||||
@guarantee BookmarkletCopy
|
||||
|
||||
@@ -203,3 +203,27 @@ invariant SidecarRoundtrip {
|
||||
parse_sidecar(m.sidecar_path).caption = m.caption
|
||||
parse_sidecar(m.sidecar_path).tags = m.tags
|
||||
}
|
||||
|
||||
rule BatchImportProcessLinkImages {
|
||||
when: BatchImportImagesRequested(project, post, file_paths, language)
|
||||
requires: not OfflineMode
|
||||
for source_path in file_paths where is_image(source_path):
|
||||
let media = ImportMedia(source_path, project)
|
||||
let analysis = AnalyzeImage(media, language)
|
||||
ensures: MediaUpdated(media, analysis)
|
||||
ensures: PostMediaLinked(media, post)
|
||||
@guidance
|
||||
-- Triggered from post editor quick action "Add Gallery Images".
|
||||
-- AI results auto-applied without user confirmation.
|
||||
-- After metadata is set, media is auto-translated to all configured blog languages.
|
||||
-- Non-image files skipped entirely.
|
||||
-- Concurrency limit from project metadata image_import_concurrency (default 4, min 1, max 8).
|
||||
-- Toast per completed image + final summary toast.
|
||||
-- On completion: [[gallery]] macro inserted into post content and post editor refreshed.
|
||||
}
|
||||
|
||||
config {
|
||||
batch_image_import_concurrency_default: Integer = 4
|
||||
batch_image_import_concurrency_min: Integer = 1
|
||||
batch_image_import_concurrency_max: Integer = 8
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user