mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-12-19 07:08:48 +08:00
Merge pull request #7202 from rekonder/aj_SCI_10281
Fix various CSS problems [SCI-10281]
This commit is contained in:
commit
3c65c7faf3
9 changed files with 13 additions and 13 deletions
|
|
@ -57,7 +57,7 @@
|
||||||
<div v-if="imageLoading" class="flex absolute top-0 items-center justify-center w-full flex-grow h-full z-10">
|
<div v-if="imageLoading" class="flex absolute top-0 items-center justify-center w-full flex-grow h-full z-10">
|
||||||
<img src="/images/medium/loading.svg" alt="Loading" />
|
<img src="/images/medium/loading.svg" alt="Loading" />
|
||||||
</div>
|
</div>
|
||||||
<img v-else :src="workflow_img" class="max-h-18 max-w-[72px]">
|
<img v-else-if="!hasError" :src="workflow_img" @error="hasError = true" class="max-h-full max-w-full">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<Description :params="{data: params, value: params.description, dtComponent: dtComponent}" />
|
<Description :params="{data: params, value: params.description, dtComponent: dtComponent}" />
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@
|
||||||
{{ experiment.description }}
|
{{ experiment.description }}
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-footer">
|
<div class="modal-footer">
|
||||||
<button type="button" class="btn btn-secondary" data-dismiss="modal">{{ i18n.t('general.cancel') }}</button>
|
<button type="button" class="btn btn-primary" data-dismiss="modal">{{ i18n.t('general.close') }}</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -7,10 +7,11 @@
|
||||||
'line-clamp-1': params.dtComponent.currentViewRender === 'table',
|
'line-clamp-1': params.dtComponent.currentViewRender === 'table',
|
||||||
'line-clamp-2': params.dtComponent.currentViewRender === 'cards'
|
'line-clamp-2': params.dtComponent.currentViewRender === 'cards'
|
||||||
}"
|
}"
|
||||||
|
:title="params.data.sa_description"
|
||||||
@click.stop="showDescriptionModal"
|
@click.stop="showDescriptionModal"
|
||||||
v-html="params.data.sa_description">
|
v-html="params.data.sa_description">
|
||||||
</span>
|
</span>
|
||||||
<span v-else class="grow" v-html="params.data.sa_description"></span>
|
<span v-else class="grow" v-html="params.data.sa_description" :title="params.data.sa_description"></span>
|
||||||
<span v-if="shouldTruncateText" @click.stop="showDescriptionModal" class="text-sn-blue cursor-pointer shrink-0 text-sm">{{ i18n.t('experiments.card.more') }}</span>
|
<span v-if="shouldTruncateText" @click.stop="showDescriptionModal" class="text-sn-blue cursor-pointer shrink-0 text-sm">{{ i18n.t('experiments.card.more') }}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
<div v-if="imageLoading" class="flex absolute top-0 items-center justify-center w-full flex-grow h-full z-10">
|
<div v-if="imageLoading" class="flex absolute top-0 items-center justify-center w-full flex-grow h-full z-10">
|
||||||
<img src="/images/medium/loading.svg" alt="Loading" class="w-4 h-4" />
|
<img src="/images/medium/loading.svg" alt="Loading" class="w-4 h-4" />
|
||||||
</div>
|
</div>
|
||||||
<img v-else :src="workflow_img" class="max-h-9 max-w-[36px]">
|
<img v-else-if="!hasError" :src="workflow_img" @error="hasError = true" class="max-h-9 max-w-[36px]">
|
||||||
</div>
|
</div>
|
||||||
<a :href="params.data.urls.show" class="hover:no-underline truncate"
|
<a :href="params.data.urls.show" class="hover:no-underline truncate"
|
||||||
:title="params.data.name">
|
:title="params.data.name">
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,8 @@ export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
workflow_img: null,
|
workflow_img: null,
|
||||||
imageLoading: false
|
imageLoading: false,
|
||||||
|
hasError: false
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@
|
||||||
<template v-slot:field>
|
<template v-slot:field>
|
||||||
<div v-if="!params.data.folder" class="flex items-center gap-1 cursor-pointer h-9" @click="openAccessModal">
|
<div v-if="!params.data.folder" class="flex items-center gap-1 cursor-pointer h-9" @click="openAccessModal">
|
||||||
<div v-for="(user, i) in visibleUsers" :key="i" :title="user.full_name">
|
<div v-for="(user, i) in visibleUsers" :key="i" :title="user.full_name">
|
||||||
<img :src="user.avatar" class="w-7 h-7" />
|
<img :src="user.avatar" class="w-7 h-7 rounded-full" />
|
||||||
</div>
|
</div>
|
||||||
<div v-if="hiddenUsers.length > 0" :title="hiddenUsersTitle"
|
<div v-if="hiddenUsers.length > 0" :title="hiddenUsersTitle"
|
||||||
class="flex shrink-0 items-center justify-center w-7 h-7 text-xs
|
class="flex shrink-0 items-center justify-center w-7 h-7 text-xs
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
<template>
|
<template>
|
||||||
<div v-if="!params.data.folder" class="flex items-center gap-1 cursor-pointer h-9" @click="openAccessModal">
|
<div v-if="!params.data.folder" class="flex items-center gap-1 cursor-pointer h-9" @click="openAccessModal">
|
||||||
<div v-for="(user, i) in visibleUsers" :key="i" :title="user.full_name">
|
<div v-for="(user, i) in visibleUsers" :key="i" :title="user.full_name">
|
||||||
<img :src="user.avatar" class="w-7 h-7" />
|
<img :src="user.avatar" class="w-7 h-7 rounded-full" />
|
||||||
</div>
|
</div>
|
||||||
<div v-if="hiddenUsers.length > 0" :title="hiddenUsersTitle"
|
<div v-if="hiddenUsers.length > 0" :title="hiddenUsersTitle"
|
||||||
class="flex shrink-0 items-center justify-center w-7 h-7 text-xs rounded-full bg-sn-dark-grey text-sn-white">
|
class="flex shrink-0 items-center justify-center w-7 h-7 text-xs rounded-full bg-sn-dark-grey text-sn-white">
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="flex flex-col h-full">
|
<div class="flex flex-col h-full" :class="{'pb-4': windowScrollerSeen && selectedRows.length === 0}">
|
||||||
<div class="relative flex flex-col flex-grow z-10">
|
<div class="relative flex flex-col flex-grow z-10">
|
||||||
<Toolbar
|
<Toolbar
|
||||||
:toolbarActions="toolbarActions"
|
:toolbarActions="toolbarActions"
|
||||||
|
|
@ -179,7 +179,8 @@ export default {
|
||||||
tableState: null,
|
tableState: null,
|
||||||
userSettingsUrl: null,
|
userSettingsUrl: null,
|
||||||
fetchedTableState: null,
|
fetchedTableState: null,
|
||||||
gridReady: false
|
gridReady: false,
|
||||||
|
windowScrollerSeen: false
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
components: {
|
components: {
|
||||||
|
|
@ -388,6 +389,7 @@ export default {
|
||||||
}));
|
}));
|
||||||
},
|
},
|
||||||
resize() {
|
resize() {
|
||||||
|
this.windowScrollerSeen = document.documentElement.scrollWidth > document.documentElement.clientWidth;
|
||||||
if (this.tableState) return;
|
if (this.tableState) return;
|
||||||
|
|
||||||
this.columnApi?.autoSizeAllColumns();
|
this.columnApi?.autoSizeAllColumns();
|
||||||
|
|
|
||||||
|
|
@ -15,10 +15,6 @@ module Lists
|
||||||
I18n.l(object.created_at, format: :full_date)
|
I18n.l(object.created_at, format: :full_date)
|
||||||
end
|
end
|
||||||
|
|
||||||
def workflow_img
|
|
||||||
rails_blob_path(object.workflowimg, only_path: true) if object.workflowimg.attached?
|
|
||||||
end
|
|
||||||
|
|
||||||
def sa_description
|
def sa_description
|
||||||
@user = scope[:user] || @instance_options[:user]
|
@user = scope[:user] || @instance_options[:user]
|
||||||
custom_auto_link(object.description,
|
custom_auto_link(object.description,
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue