mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-11-09 16:01:30 +08:00
Merge pull request #4193 from aignatov-bio/ai-sci-6932-fix-css-for-steps
CSS fixes for steps [SCI-6932]
This commit is contained in:
commit
ed5907a5fa
7 changed files with 72 additions and 42 deletions
|
|
@ -1,4 +1,26 @@
|
||||||
.task-protocol {
|
.task-protocol {
|
||||||
|
.protocol-name {
|
||||||
|
.sci-inline-edit__view.blank,
|
||||||
|
textarea {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.protocol-step-actions {
|
||||||
|
margin-left: -6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.protocol-buttons-group {
|
||||||
|
column-gap: .25em;
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: auto auto auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.portocol-header-left-part {
|
||||||
|
align-items: baseline;
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
|
||||||
.insert-step {
|
.insert-step {
|
||||||
align-items: center;
|
align-items: center;
|
||||||
color: $color-concrete;
|
color: $color-concrete;
|
||||||
|
|
@ -27,6 +49,12 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.protocol-description {
|
||||||
|
margin-bottom: 2em;
|
||||||
|
padding-left: 1em;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
.protocol-options-dropdown {
|
.protocol-options-dropdown {
|
||||||
a {
|
a {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
|
|
||||||
|
|
@ -79,7 +79,7 @@
|
||||||
|
|
||||||
.repositories-assign-container {
|
.repositories-assign-container {
|
||||||
flex-grow: 1;
|
flex-grow: 1;
|
||||||
max-width: 200px;
|
max-width: 150px;
|
||||||
|
|
||||||
.btn {
|
.btn {
|
||||||
text-align: left;
|
text-align: left;
|
||||||
|
|
@ -552,7 +552,7 @@
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-grow: 1;
|
flex-grow: 1;
|
||||||
|
|
||||||
:not(:first-child):not(.dropdown-menu) {
|
> :not(:first-child):not(.dropdown-menu) {
|
||||||
margin-left: .5em;
|
margin-left: .5em;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -589,7 +589,7 @@
|
||||||
margin: 0;
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.status-buttons :not(:first-child):not(.dropdown-menu) {
|
.status-buttons > :not(:first-child):not(.dropdown-menu) {
|
||||||
margin-left: 0;
|
margin-left: 0;
|
||||||
margin-top: .5em;
|
margin-top: .5em;
|
||||||
}
|
}
|
||||||
|
|
@ -615,7 +615,7 @@
|
||||||
text-align: left;
|
text-align: left;
|
||||||
}
|
}
|
||||||
|
|
||||||
.status-buttons :not(:first-child):not(.dropdown-menu) {
|
.status-buttons > :not(:first-child):not(.dropdown-menu) {
|
||||||
margin-left: 0;
|
margin-left: 0;
|
||||||
margin-top: .5em;
|
margin-top: .5em;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -67,6 +67,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.protocol-step-actions {
|
.protocol-step-actions {
|
||||||
|
margin-left: -6px;
|
||||||
margin-top: 2em;
|
margin-top: 2em;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -453,7 +453,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.experiment-name {
|
.experiment-name {
|
||||||
@include font-main;
|
@include font-h1;
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@
|
||||||
|
|
||||||
.step-container {
|
.step-container {
|
||||||
border: $border-transparent;
|
border: $border-transparent;
|
||||||
margin: 20px 0 20px -1.5em;
|
margin: 6px 0 6px -1.5em;
|
||||||
padding: 8px 24px 8px 0;
|
padding: 8px 24px 8px 0;
|
||||||
|
|
||||||
.step-header {
|
.step-header {
|
||||||
|
|
@ -46,12 +46,14 @@
|
||||||
.step-position {
|
.step-position {
|
||||||
@include font-main;
|
@include font-main;
|
||||||
flex-shrink: 0;
|
flex-shrink: 0;
|
||||||
|
font-weight: bold;
|
||||||
line-height: 24px;
|
line-height: 24px;
|
||||||
margin: 0 4px;
|
margin: 0 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.step-name-container {
|
.step-name-container {
|
||||||
flex-grow: 1;
|
flex-grow: 1;
|
||||||
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
|
|
||||||
.step-actions-container {
|
.step-actions-container {
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="task-protocol">
|
<div class="task-protocol">
|
||||||
<div class="task-section-header" v-if="!inRepository">
|
<div class="task-section-header" v-if="!inRepository">
|
||||||
|
<div class="portocol-header-left-part">
|
||||||
<a class="task-section-caret" role="button" data-toggle="collapse" href="#protocol-content" aria-expanded="true" aria-controls="protocol-content">
|
<a class="task-section-caret" role="button" data-toggle="collapse" href="#protocol-content" aria-expanded="true" aria-controls="protocol-content">
|
||||||
<i class="fas fa-caret-right"></i>
|
<i class="fas fa-caret-right"></i>
|
||||||
<div class="task-section-title">
|
<div class="task-section-title">
|
||||||
|
|
@ -10,7 +11,9 @@
|
||||||
<div class="my-module-protocol-status">
|
<div class="my-module-protocol-status">
|
||||||
<!-- protocol status dropdown gets mounted here -->
|
<!-- protocol status dropdown gets mounted here -->
|
||||||
</div>
|
</div>
|
||||||
<div class="sci-btn-group actions-block">
|
</div>
|
||||||
|
<div class="actions-block">
|
||||||
|
<div class="protocol-buttons-group">
|
||||||
<a v-if="urls.add_step_url" class="btn btn-primary" @click="addStep(steps.length)">
|
<a v-if="urls.add_step_url" class="btn btn-primary" @click="addStep(steps.length)">
|
||||||
<span class="fas fa-plus" aria-hidden="true"></span>
|
<span class="fas fa-plus" aria-hidden="true"></span>
|
||||||
<span>{{ i18n.t("protocols.steps.new_step") }}</span>
|
<span>{{ i18n.t("protocols.steps.new_step") }}</span>
|
||||||
|
|
@ -27,6 +30,7 @@
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
<div v-if="protocol.id" id="protocol-content" class="protocol-content collapse in" aria-expanded="true">
|
<div v-if="protocol.id" id="protocol-content" class="protocol-content collapse in" aria-expanded="true">
|
||||||
<div class="protocol-description">
|
<div class="protocol-description">
|
||||||
<div class="protocol-name">
|
<div class="protocol-name">
|
||||||
|
|
@ -44,7 +48,7 @@
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<ProtocolMetadata v-if="protocol.attributes && protocol.attributes.in_repository" :protocol="protocol" @update="updateProtocol"/>
|
<ProtocolMetadata v-if="protocol.attributes && protocol.attributes.in_repository" :protocol="protocol" @update="updateProtocol"/>
|
||||||
<div v-if="urls.update_protocol_description_url" class="protocol-description">
|
<div v-if="urls.update_protocol_description_url">
|
||||||
<Tinymce
|
<Tinymce
|
||||||
:value="protocol.attributes.description"
|
:value="protocol.attributes.description"
|
||||||
:value_html="protocol.attributes.description_view"
|
:value_html="protocol.attributes.description_view"
|
||||||
|
|
@ -64,8 +68,7 @@
|
||||||
<span class="fas fa-plus" aria-hidden="true"></span>
|
<span class="fas fa-plus" aria-hidden="true"></span>
|
||||||
<span>{{ i18n.t("protocols.steps.new_step") }}</span>
|
<span>{{ i18n.t("protocols.steps.new_step") }}</span>
|
||||||
</a>
|
</a>
|
||||||
|
<div v-if="steps.length > 0" class="protocol-step-actions">
|
||||||
<div class="protocol-step-actions">
|
|
||||||
<button class="btn btn-light" @click="collapseSteps">
|
<button class="btn btn-light" @click="collapseSteps">
|
||||||
<span class="fas fa-caret-up"></span>
|
<span class="fas fa-caret-up"></span>
|
||||||
{{ i18n.t("protocols.steps.collapse_label") }}
|
{{ i18n.t("protocols.steps.collapse_label") }}
|
||||||
|
|
@ -146,7 +149,7 @@
|
||||||
protocol: {
|
protocol: {
|
||||||
attributes: {}
|
attributes: {}
|
||||||
},
|
},
|
||||||
steps: {},
|
steps: [],
|
||||||
reordering: false
|
reordering: false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -93,17 +93,13 @@
|
||||||
<li class="title">
|
<li class="title">
|
||||||
{{ i18n.t('protocols.steps.options_dropdown.title') }}
|
{{ i18n.t('protocols.steps.options_dropdown.title') }}
|
||||||
</li>
|
</li>
|
||||||
<li v-if="urls.reorder_elements_url" class="action">
|
<li v-if="urls.reorder_elements_url" class="action" @click="openReorderModal" :class="{ 'disabled': elements.length < 2 }">
|
||||||
<a @click="openReorderModal" :class="{ 'disabled': elements.length < 2 }">
|
|
||||||
<i class="fas fa-arrows-alt-v"></i>
|
<i class="fas fa-arrows-alt-v"></i>
|
||||||
{{ i18n.t('protocols.steps.options_dropdown.rearrange') }}
|
{{ i18n.t('protocols.steps.options_dropdown.rearrange') }}
|
||||||
</a>
|
|
||||||
</li>
|
</li>
|
||||||
<li v-if="urls.delete_url" class="action">
|
<li v-if="urls.delete_url" class="action" @click="showDeleteModal">
|
||||||
<a @click="showDeleteModal">
|
|
||||||
<i class="fas fa-trash"></i>
|
<i class="fas fa-trash"></i>
|
||||||
{{ i18n.t('protocols.steps.options_dropdown.delete') }}
|
{{ i18n.t('protocols.steps.options_dropdown.delete') }}
|
||||||
</a>
|
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue