Begins tests with theme dumb list items (left commented). New settings on MediaUploader for attachments. New style for inputs.
This commit is contained in:
parent
3f576063ca
commit
cd30053d95
|
@ -23,6 +23,7 @@
|
|||
:title="$i18n.getHelperTitle('categories', 'name')"
|
||||
:message="$i18n.getHelperMessage('categories', 'name')"/>
|
||||
<b-input
|
||||
:class="{'has-content': form.name != undefined && form.name != ''}"
|
||||
id="tainacan-text-name"
|
||||
v-model="form.name"
|
||||
@focus="clearErrors('name')"
|
||||
|
@ -39,6 +40,7 @@
|
|||
:title="$i18n.getHelperTitle('categories', 'description')"
|
||||
:message="$i18n.getHelperMessage('categories', 'description')"/>
|
||||
<b-input
|
||||
:class="{'has-content': form.description != undefined && form.description != ''}"
|
||||
id="tainacan-text-description"
|
||||
type="textarea"
|
||||
v-model="form.description"
|
||||
|
@ -79,6 +81,7 @@
|
|||
:message="$i18n.getHelperMessage('categories', 'slug')"/>
|
||||
<b-icon :class="{'is-loading': isUpdatingSlug}"/>
|
||||
<b-input
|
||||
:class="{'has-content': form.slug != undefined && form.slug != ''}"
|
||||
@input="updateSlug()"
|
||||
id="tainacan-text-slug"
|
||||
v-model="form.slug"
|
||||
|
|
|
@ -106,6 +106,7 @@
|
|||
:title="$i18n.getHelperTitle('collections', 'name')"
|
||||
:message="$i18n.getHelperMessage('collections', 'name')"/>
|
||||
<b-input
|
||||
:class="{'has-content': form.name != undefined && form.name != ''}"
|
||||
id="tainacan-text-name"
|
||||
v-model="form.name"
|
||||
@focus="clearErrors('name')"/>
|
||||
|
@ -121,6 +122,7 @@
|
|||
:title="$i18n.getHelperTitle('collections', 'description')"
|
||||
:message="$i18n.getHelperMessage('collections', 'description')"/>
|
||||
<b-input
|
||||
:class="{'has-content': form.description != undefined && form.description != ''}"
|
||||
id="tainacan-text-description"
|
||||
type="textarea"
|
||||
v-model="form.description"
|
||||
|
@ -241,6 +243,7 @@
|
|||
:title="$i18n.getHelperTitle('collections', 'slug')"
|
||||
:message="$i18n.getHelperMessage('collections', 'slug')"/>
|
||||
<b-input
|
||||
:class="{'has-content': form.slug != undefined && form.slug != ''}"
|
||||
id="tainacan-text-slug"
|
||||
v-model="form.slug"
|
||||
@focus="clearErrors('slug')"/>
|
||||
|
@ -700,7 +703,7 @@ export default {
|
|||
}
|
||||
}
|
||||
.selected-cover-page {
|
||||
background-color: $tainacan-input-color;
|
||||
background-color: $tainacan-input-background;
|
||||
padding: 8px;
|
||||
font-size: .85rem;
|
||||
.span { vertical-align: middle;}
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
:message="$i18n.getHelperMessage('fields', 'name')"/>
|
||||
</label>
|
||||
<b-input
|
||||
:class="{'has-content': editForm.name != undefined && editForm.name != ''}"
|
||||
v-model="editForm.name"
|
||||
name="name"
|
||||
@focus="clearErrors('name')"/>
|
||||
|
@ -34,6 +35,7 @@
|
|||
:message="$i18n.getHelperMessage('fields', 'description')"/>
|
||||
</label>
|
||||
<b-input
|
||||
:class="{'has-content': editForm.description != undefined && editForm.description != ''}"
|
||||
type="textarea"
|
||||
name="description"
|
||||
v-model="editForm.description"
|
||||
|
|
|
@ -16,7 +16,8 @@
|
|||
:title="$i18n.getHelperTitle('filters', 'name')"
|
||||
:message="$i18n.getHelperMessage('filters', 'name')"/>
|
||||
</label>
|
||||
<b-input
|
||||
<b-input
|
||||
:class="{'has-content': editForm.name != undefined && editForm.name != ''}"
|
||||
v-model="editForm.name"
|
||||
name="name"
|
||||
@focus="clearErrors('name')"/>
|
||||
|
@ -32,7 +33,8 @@
|
|||
:title="$i18n.getHelperTitle('filters', 'description')"
|
||||
:message="$i18n.getHelperMessage('filters', 'description')"/>
|
||||
</label>
|
||||
<b-input
|
||||
<b-input
|
||||
:class="{'has-content': editForm.description != undefined && editForm.description != ''}"
|
||||
type="textarea"
|
||||
name="description"
|
||||
v-model="editForm.description"
|
||||
|
|
|
@ -135,7 +135,8 @@
|
|||
<h2>{{ $i18n.get('instruction_write_text') }}</h2>
|
||||
<hr>
|
||||
</div>
|
||||
<b-input
|
||||
<b-input
|
||||
:class="{'has-content': textContent != undefined && textContent != ''}"
|
||||
type="textarea"
|
||||
v-model="textContent"/>
|
||||
|
||||
|
@ -170,7 +171,9 @@
|
|||
<h2>{{ $i18n.get('instruction_insert_url') }}</h2>
|
||||
<hr>
|
||||
</div>
|
||||
<b-input v-model="urlLink"/>
|
||||
<b-input
|
||||
:class="{'has-content': urlLink != undefined && urlLink != ''}"
|
||||
v-model="urlLink"/>
|
||||
|
||||
<div class="field is-grouped form-submit">
|
||||
<div class="control">
|
||||
|
@ -500,6 +503,7 @@ export default {
|
|||
}
|
||||
}
|
||||
);
|
||||
|
||||
},
|
||||
toggleCollapseAll() {
|
||||
this.collapseAll = !this.collapseAll;
|
||||
|
@ -599,7 +603,7 @@ export default {
|
|||
height: 72px;
|
||||
width: 72px;
|
||||
border: none;
|
||||
background-color: $tainacan-input-color;
|
||||
background-color: $tainacan-input-background;
|
||||
color: $secondary;
|
||||
margin-bottom: 6px;
|
||||
&:hover {
|
||||
|
|
|
@ -51,6 +51,7 @@
|
|||
:message="$i18n.getHelperMessage('terms', 'name')"/>
|
||||
</label>
|
||||
<b-input
|
||||
:class="{'has-content': editForm.name != undefined && editForm.name != ''}"
|
||||
v-model="editForm.name"
|
||||
name="name"
|
||||
@focus="clearErrors({ name: 'name', repeated: 'repeated' })"/>
|
||||
|
@ -67,6 +68,7 @@
|
|||
:message="$i18n.getHelperMessage('terms', 'description')"/>
|
||||
</label>
|
||||
<b-input
|
||||
:class="{'has-content': editForm.description != undefined && editForm.description != ''}"
|
||||
type="textarea"
|
||||
name="description"
|
||||
v-model="editForm.description"
|
||||
|
|
|
@ -8,19 +8,25 @@ export default {
|
|||
wp.media.view.settings.post = {
|
||||
id: this.params.relatedPostId
|
||||
}
|
||||
|
||||
|
||||
this.frame = wp.media({
|
||||
button: {
|
||||
text: this.params.button_labels.frame_button
|
||||
},
|
||||
content: 'upload', // First view that is opened
|
||||
autoSelect: true,
|
||||
states: [
|
||||
new wp.media.controller.Library({
|
||||
new wp.media.controller.MediaLibrary({
|
||||
title: this.params.button_labels.frame_title,
|
||||
library: wp.media.query({
|
||||
uploadedTo: this.params.relatedPostId
|
||||
status: null,
|
||||
type: null,
|
||||
uploadedTo: wp.media.view.settings.post.id
|
||||
}),
|
||||
uploader: true,
|
||||
multiple: true,
|
||||
date: false
|
||||
date: false,
|
||||
uploadedTo: wp.media.view.settings.post.id
|
||||
})
|
||||
]
|
||||
});
|
||||
|
@ -34,10 +40,13 @@ export default {
|
|||
mejsSettings = window._wpmejsSettings || {};
|
||||
attachments = this.frame.state().get( 'selection' ).toJSON();
|
||||
|
||||
wp.media.view.settings.post = {
|
||||
id: this.params.relatedPostId
|
||||
}
|
||||
|
||||
this.params.attachments = attachments;
|
||||
this.params.onSave(attachments);
|
||||
// Set the Customizer setting; the callback takes care of rendering.
|
||||
//this.setting( attachment.id );
|
||||
node = this.container.find( 'audio, video' ).get(0);
|
||||
|
||||
// Initialize audio/video previews.
|
||||
|
@ -71,6 +80,8 @@ export default {
|
|||
close: false
|
||||
},
|
||||
uploader: true,
|
||||
content: 'upload', // First view that is opened
|
||||
autoSelect: true,
|
||||
states: [
|
||||
new wp.media.controller.Library({
|
||||
title: this.params.button_labels.frame_title,
|
||||
|
@ -80,7 +91,6 @@ export default {
|
|||
}),
|
||||
multiple: false,
|
||||
date: false,
|
||||
filterable: true,
|
||||
priority: 20,
|
||||
suggestedWidth: this.params.width,
|
||||
suggestedHeight: this.params.height,
|
||||
|
@ -128,7 +138,12 @@ export default {
|
|||
text: l10n.select,
|
||||
close: false
|
||||
},
|
||||
library: wp.media.query({
|
||||
type: 'image',
|
||||
uploadedTo: this.params.relatedPostId
|
||||
}),
|
||||
uploader: true,
|
||||
content: 'upload', // First view that is opened
|
||||
states: [
|
||||
new wp.media.controller.Library({
|
||||
title: this.params.button_labels.frame_title,
|
||||
|
@ -178,6 +193,7 @@ export default {
|
|||
button: {
|
||||
text: this.params.button_labels.frame_button
|
||||
},
|
||||
content: 'upload', // First view that is opened
|
||||
states: [
|
||||
new wp.media.controller.Library({
|
||||
title: this.params.button_labels.frame_title,
|
||||
|
|
|
@ -81,7 +81,9 @@
|
|||
:table-fields="tableFields"
|
||||
:pref-table-fields="prefTableFields"/>
|
||||
</div>
|
||||
|
||||
<div
|
||||
:items="items"
|
||||
id="theme-items-list" />
|
||||
<!-- LISTING RESULTS ------------------------- -->
|
||||
<div class="table-container above-subheader">
|
||||
<b-loading
|
||||
|
@ -189,6 +191,16 @@
|
|||
}
|
||||
},
|
||||
created() {
|
||||
/*
|
||||
document.addEventListener('tainacan-items-change', () => {
|
||||
var themeList = document.getElementById('theme-items-list');
|
||||
var items = themeList.attributes.items.value;
|
||||
|
||||
var e = document.createElement('p');
|
||||
e.innerHTML = items;
|
||||
|
||||
themeList.appendChild(e);
|
||||
}); */
|
||||
this.isRepositoryLevel = (this.collectionId == undefined);
|
||||
|
||||
this.$eventBusSearch.$on('isLoadingItems', isLoadingItems => {
|
||||
|
@ -337,7 +349,7 @@
|
|||
width: $filter-menu-width;
|
||||
max-width: $filter-menu-width;
|
||||
min-height: 100%;
|
||||
background-color: $tainacan-input-color;
|
||||
background-color: $tainacan-input-background;
|
||||
padding: $page-small-side-padding;
|
||||
float: left;
|
||||
height: 100%;
|
||||
|
|
|
@ -19,7 +19,9 @@ $success: #25a088;
|
|||
$success-invert: findColorInvert($success);
|
||||
|
||||
$separator-color: #2b98a4;
|
||||
$tainacan-input-color: #f0f0f0;
|
||||
$tainacan-input-color: #1d1d1d;
|
||||
$tainacan-input-background: #e5e5e5;
|
||||
$tainacan-placeholder-color: #898d8f;
|
||||
$draggable-border-color: #d8d8d8;
|
||||
|
||||
$gray: #b1b1b1;
|
||||
|
@ -73,6 +75,11 @@ $link: $secondary;
|
|||
$link-invert: $secondary-invert;
|
||||
$link-focus-border: $secondary;
|
||||
|
||||
// Placeholder
|
||||
$text-light: $tainacan-placeholder-color;
|
||||
|
||||
// Bulma Inputs
|
||||
|
||||
// Table
|
||||
$table-head-cell-color: $gray-light;
|
||||
$table-head-cell-border-width: 0 0 1px !important;
|
||||
|
|
|
@ -162,12 +162,25 @@ html {
|
|||
font-size: 14px;
|
||||
border: none;
|
||||
border-radius: 1px !important;
|
||||
background-color: $tainacan-input-color;
|
||||
color: black;
|
||||
background-color: $tainacan-input-background;
|
||||
color: $tainacan-input-color;
|
||||
box-shadow: none;
|
||||
transition: background-color 0.1s;
|
||||
|
||||
&.is-danger {
|
||||
background-color: #ece0e0;
|
||||
background-color: #e7dede;
|
||||
}
|
||||
|
||||
&:focus, &:active {
|
||||
box-shadow: none;
|
||||
background-color: white;
|
||||
border: 1px solid $tainacan-input-background;
|
||||
}
|
||||
}
|
||||
.control.has-content {
|
||||
.input, .textarea {
|
||||
background-color: white;
|
||||
border: 1px solid $tainacan-input-background;
|
||||
}
|
||||
}
|
||||
.radio {
|
||||
|
@ -192,7 +205,7 @@ html {
|
|||
padding: 2px 25px 2px 15px!important;
|
||||
margin-top: 0px !important;
|
||||
margin-bottom: 0px !important;
|
||||
background-color: $tainacan-input-color;
|
||||
background-color: $tainacan-input-background;
|
||||
color: black;
|
||||
&:focus>option:checked, &:focus>option:hover {
|
||||
background-color: $primary-lighter !important;
|
||||
|
@ -296,7 +309,7 @@ html {
|
|||
}
|
||||
}
|
||||
&:hover input[type="checkbox"] + .check {
|
||||
background-color: $tainacan-input-color;
|
||||
background-color: $tainacan-input-background;
|
||||
}
|
||||
|
||||
&:focus input[type="checkbox"] + .check,
|
||||
|
|
|
@ -28,7 +28,7 @@ return [
|
|||
'remove' => __( 'Remove', 'tainacan' ),
|
||||
'save' => __( 'Save', 'tainacan' ),
|
||||
'next' => __( 'Next', 'tainacan' ),
|
||||
'return' => __( 'Return', 'tainacan' ),
|
||||
'return' => __( 'Return', 'tainacan' ),
|
||||
'see' => __( 'See', 'tainacan' ),
|
||||
'search' => __( 'Search', 'tainacan' ),
|
||||
'advanced_search' => __( 'Advanced Search', 'tainacan' ),
|
||||
|
|
|
@ -16,7 +16,9 @@
|
|||
style="padding-left: 0px;">
|
||||
|
||||
<b-field :label="$i18n.get('label_name')">
|
||||
<b-input v-model="name"/>
|
||||
<b-input
|
||||
:class="{'has-content': name != undefined && name != ''}"
|
||||
v-model="name"/>
|
||||
</b-field>
|
||||
|
||||
<b-field :label="$i18n.get('label_parent_term')">
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
<template>
|
||||
<b-datepicker
|
||||
:class="{'has-content': dateValue != undefined && dateValue != ''}"
|
||||
:id="id"
|
||||
v-model="dateValue"
|
||||
@blur="onBlur"
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
<template>
|
||||
<b-input
|
||||
:class="{'has-content': inputValue != undefined && inputValue != ''}"
|
||||
:id="id"
|
||||
type="number"
|
||||
:value="inputValue"
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
<template>
|
||||
<b-input
|
||||
:class="{'has-content': inputValue != undefined && inputValue != ''}"
|
||||
:id="id"
|
||||
:value="inputValue"
|
||||
@blur="onBlur"
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
<template>
|
||||
<b-input
|
||||
:class="{'has-content': inputValue != undefined && inputValue != ''}"
|
||||
:id="id"
|
||||
type="textarea"
|
||||
:value="inputValue"
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<div>
|
||||
<div v-if="type === 'date'">
|
||||
<b-datepicker
|
||||
:class="{'has-content': date_init != undefined && date_init != ''}"
|
||||
size="is-small"
|
||||
v-model="date_init"
|
||||
@input="validate_values()"
|
||||
|
@ -9,6 +10,7 @@
|
|||
icon="calendar-today"/>
|
||||
<br>
|
||||
<b-datepicker
|
||||
:class="{'has-content': date_end != undefined && date_end != ''}"
|
||||
size="is-small"
|
||||
v-model="date_end"
|
||||
@input="validate_values()"
|
||||
|
@ -21,12 +23,14 @@
|
|||
class="columns"
|
||||
v-else>
|
||||
<b-input
|
||||
:class="{'has-content': value_init != undefined && value_init != ''}"
|
||||
size="is-small"
|
||||
type="number"
|
||||
@input="validate_values()"
|
||||
class="column"
|
||||
v-model="value_init"/>
|
||||
<b-input
|
||||
:class="{'has-content': value_end != undefined && value_end != ''}"
|
||||
size="is-small"
|
||||
type="number"
|
||||
@input="validate_values()"
|
||||
|
|
|
@ -12,6 +12,7 @@ export default {
|
|||
collectionId: undefined
|
||||
},
|
||||
created(){
|
||||
|
||||
this.$on('input', data => {
|
||||
this.$store.dispatch('search/setPage', 1);
|
||||
|
||||
|
@ -98,6 +99,8 @@ export default {
|
|||
this.$store.dispatch('collection/fetchItems', this.collectionId).then((res) => {
|
||||
this.$emit( 'isLoadingItems', false);
|
||||
this.$emit( 'hasFiltered', res.hasFiltered);
|
||||
//var event = new Event('tainacan-items-change')
|
||||
//document.dispatchEvent(event);
|
||||
})
|
||||
.catch(() => {
|
||||
this.$emit( 'isLoadingItems', false);
|
||||
|
|
Loading…
Reference in New Issue