Browse Source

add missing `^`

amrbashir 9 months ago
parent
commit
c0d529a836

+ 1 - 1
crates/tauri-cli/config.schema.json

@@ -842,7 +842,7 @@
         {
           "description": "Color hex string, for example: #fff, #ffffff, or #ffffffff.",
           "type": "string",
-          "pattern": "#?([A-Fa-f0-9]{3}|[A-Fa-f0-9]{6}|[A-Fa-f0-9]{8})$"
+          "pattern": "^#?([A-Fa-f0-9]{3}|[A-Fa-f0-9]{6}|[A-Fa-f0-9]{8})$"
         },
         {
           "description": "Array of RGB colors. Each value has minimum of 0 and maximum of 255.",

+ 1 - 1
crates/tauri-schema-generator/schemas/config.schema.json

@@ -842,7 +842,7 @@
         {
           "description": "Color hex string, for example: #fff, #ffffff, or #ffffffff.",
           "type": "string",
-          "pattern": "#?([A-Fa-f0-9]{3}|[A-Fa-f0-9]{6}|[A-Fa-f0-9]{8})$"
+          "pattern": "^#?([A-Fa-f0-9]{3}|[A-Fa-f0-9]{6}|[A-Fa-f0-9]{8})$"
         },
         {
           "description": "Array of RGB colors. Each value has minimum of 0 and maximum of 255.",

+ 1 - 1
crates/tauri-utils/src/config.rs

@@ -1380,7 +1380,7 @@ impl schemars::JsonSchema for Color {
     let schemars::schema::Schema::Object(str_schema) = any_of.first_mut().unwrap() else {
       unreachable!()
     };
-    str_schema.string().pattern = Some("#?([A-Fa-f0-9]{3}|[A-Fa-f0-9]{6}|[A-Fa-f0-9]{8})$".into());
+    str_schema.string().pattern = Some("^#?([A-Fa-f0-9]{3}|[A-Fa-f0-9]{6}|[A-Fa-f0-9]{8})$".into());
 
     schema.into()
   }