summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--examples/db.json13
-rw-r--r--themes/okadmin/public/css/main.css11
-rw-r--r--themes/okadmin/templates/partials/inputs.liquid6
3 files changed, 15 insertions, 15 deletions
diff --git a/examples/db.json b/examples/db.json
index 1061086..cede8bc 100644
--- a/examples/db.json
+++ b/examples/db.json
@@ -27,18 +27,7 @@
"id": "bagel",
"title": "nice",
"color": "blue",
- "images": [
- {
- "uri": [
- "http://del.h-cdn.co/assets/cm/15/10/54f928d7ada8d_-_1347910942518.jpg",
- "https://ltho.s3.amazonaws.com/45c29c6d-2832-46f1-b0d3-6f847b6f42e4.png"
- ],
- "caption": [
- "boop",
- "Errorrrrr"
- ]
- }
- ],
+ "images": [],
"video": {
"url": "https://vimeo.com/112498725",
"type": "vimeo",
diff --git a/themes/okadmin/public/css/main.css b/themes/okadmin/public/css/main.css
index 23a82d2..982d6ad 100644
--- a/themes/okadmin/public/css/main.css
+++ b/themes/okadmin/public/css/main.css
@@ -255,6 +255,17 @@ li.image-element:hover .remove-image {
display: none;
}
+
+.errors {
+ background: white;
+ padding: 10px;
+ width: 100%;
+ line-height: 1.4em;
+}
+.errors .message {
+ color: red;
+}
+
.clear {
clear: both;
}
diff --git a/themes/okadmin/templates/partials/inputs.liquid b/themes/okadmin/templates/partials/inputs.liquid
index 41cb3df..9710b8f 100644
--- a/themes/okadmin/templates/partials/inputs.liquid
+++ b/themes/okadmin/templates/partials/inputs.liquid
@@ -43,15 +43,15 @@
<ol>
{% for image in spec.value %}
<li class="image-element">
- <input type="hidden" name="{{name}}[][uri]" value="{{image.uri}}">
- <textarea class="caption" name="{{name}}[][caption]">{{image.caption}}</textarea>
+ <input type="hidden" name="{{name}}[uri]" value="{{image.uri}}">
+ <textarea class="caption" name="{{name}}[caption]">{{image.caption}}</textarea>
<img src="{{image.uri}}" alt="{{image.caption}}">
<button class="remove-image">♲</button>
</li>
{% endfor %}
</ol>
<div class="add-image-button">
- <input id="file" type="file" accept="image/*">
+ <input id="file" type="file" accept="image/*" multiple>
<span>+ Add images</span>
</div>
<script type="text/html" id="captioned-image-template">