upload selector improvements
This commit is contained in:
		@ -225,7 +225,7 @@ export default {
 | 
			
		||||
                                     : fetch(url, Model.getOptions()).then(d => d.json())
 | 
			
		||||
 | 
			
		||||
            promise = promise.then(items => {
 | 
			
		||||
                this.items = items || []
 | 
			
		||||
                this.items = items.filter((i) => i) || []
 | 
			
		||||
                this.promise = null;
 | 
			
		||||
                this.move(0)
 | 
			
		||||
                return items
 | 
			
		||||
 | 
			
		||||
@ -7,22 +7,22 @@
 | 
			
		||||
            <div class="flex-row align-right">
 | 
			
		||||
                <div class="field has-addons">
 | 
			
		||||
                    <p class="control">
 | 
			
		||||
                        <a :class="['button','p-2', page == Page.Text ? 'is-primary' : 'is-light']"
 | 
			
		||||
                        <button type="button" :class="['button','p-2', page == Page.Text ? 'is-primary' : 'is-light']"
 | 
			
		||||
                                @click="page = Page.Text">
 | 
			
		||||
                            <span class="icon is-small">
 | 
			
		||||
                                <i class="fa fa-pencil"></i>
 | 
			
		||||
                            </span>
 | 
			
		||||
                            <span>Texte</span>
 | 
			
		||||
                        </a>
 | 
			
		||||
                        </button>
 | 
			
		||||
                    </p>
 | 
			
		||||
                    <p class="control">
 | 
			
		||||
                        <a :class="['button','p-2', page == Page.List ? 'is-primary' : 'is-light']"
 | 
			
		||||
                        <button type="button" :class="['button','p-2', page == Page.List ? 'is-primary' : 'is-light']"
 | 
			
		||||
                                @click="page = Page.List">
 | 
			
		||||
                            <span class="icon is-small">
 | 
			
		||||
                                <i class="fa fa-list"></i>
 | 
			
		||||
                            </span>
 | 
			
		||||
                            <span>Liste</span>
 | 
			
		||||
                        </a>
 | 
			
		||||
                        </button>
 | 
			
		||||
                    </p>
 | 
			
		||||
                </div>
 | 
			
		||||
            </div>
 | 
			
		||||
@ -47,12 +47,12 @@
 | 
			
		||||
                <template v-slot:row-tail="data">
 | 
			
		||||
                    <slot v-if="$slots['row-tail']" :name="row-tail" v-bind="data"/>
 | 
			
		||||
                    <td class="align-right pr-0">
 | 
			
		||||
                        <a class="button square"
 | 
			
		||||
                        <button type="button" class="button square"
 | 
			
		||||
                                @click.stop="items.splice(data.row,1)"
 | 
			
		||||
                                :title="labels.remove_track"
 | 
			
		||||
                                :aria-label="labels.remove_track">
 | 
			
		||||
                            <span class="icon"><i class="fa fa-trash" /></span>
 | 
			
		||||
                        </a>
 | 
			
		||||
                        </button>
 | 
			
		||||
                    </td>
 | 
			
		||||
                </template>
 | 
			
		||||
            </a-rows>
 | 
			
		||||
@ -60,33 +60,33 @@
 | 
			
		||||
 | 
			
		||||
        <div class="flex-row">
 | 
			
		||||
            <div class="flex-grow-1 flex-row">
 | 
			
		||||
                <div class="field ml-3">
 | 
			
		||||
                <div class="field">
 | 
			
		||||
                    <p class="control">
 | 
			
		||||
                        <a class="button is-info"
 | 
			
		||||
                        <button type="button" class="button is-info"
 | 
			
		||||
                            @click="$refs.settings.open()">
 | 
			
		||||
                            <span class="icon is-small">
 | 
			
		||||
                                <i class="fa fa-cog"></i>
 | 
			
		||||
                            </span>
 | 
			
		||||
                            <span>Options</span>
 | 
			
		||||
                        </a>
 | 
			
		||||
                        </button>
 | 
			
		||||
                    </p>
 | 
			
		||||
                </div>
 | 
			
		||||
            </div>
 | 
			
		||||
            <div class="flex-grow-1 align-right">
 | 
			
		||||
                <a class="button square is-warning p-2"
 | 
			
		||||
                <button type="button" class="button square is-warning p-2"
 | 
			
		||||
                        @click="loadData({items: this.initData.items},true)"
 | 
			
		||||
                        :title="labels.discard_changes"
 | 
			
		||||
                        :aria-label="labels.discard_changes"
 | 
			
		||||
                        >
 | 
			
		||||
                    <span class="icon"><i class="fa fa-rotate" /></span>
 | 
			
		||||
                </a>
 | 
			
		||||
                <a class="button square is-primary p-2" v-if="page == Page.List"
 | 
			
		||||
                </button>
 | 
			
		||||
                <button type="button" class="button square is-primary p-2" v-if="page == Page.List"
 | 
			
		||||
                        @click="this.set.push(new this.set.model())"
 | 
			
		||||
                        :title="labels.add_track"
 | 
			
		||||
                        :aria-label="labels.add_track"
 | 
			
		||||
                        >
 | 
			
		||||
                    <span class="icon"><i class="fa fa-plus"/></span>
 | 
			
		||||
                </a>
 | 
			
		||||
                </button>
 | 
			
		||||
            </div>
 | 
			
		||||
        </div>
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@ -161,8 +161,6 @@
 | 
			
		||||
        color: var(--button-fg);
 | 
			
		||||
        background-color: var(--button-bg);
 | 
			
		||||
 | 
			
		||||
        &.smaller { font-size: v.$text-size-smaller; }
 | 
			
		||||
        &.small { font-size: v.$text-size-small; }
 | 
			
		||||
        &.square { min-width: 2.5em; }
 | 
			
		||||
        &.secondary { background-color: var(--button-sec-bg); }
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user