1
0
mirror of https://github.com/mattermost/focalboard.git synced 2024-12-03 08:45:40 +02:00

Fixing style problems on hover editable board templates (#2221)

* Fixing style problems on hover editable board templates

* Making template version relevant to detect if the template is builtin or not

* Fixing snapshots

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
This commit is contained in:
Jesús Espino 2022-02-09 15:36:27 +01:00 committed by GitHub
parent 0d65c9eac9
commit 10686f6b23
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 11 additions and 2 deletions

View File

@ -67,6 +67,7 @@ function createBoard(block?: Block): Board {
description: block?.fields.description || '',
icon: block?.fields.icon || '',
isTemplate: block?.fields.isTemplate || false,
templateVer: block?.fields.templateVer || 0,
columnCalculations: block?.fields.columnCalculations || [],
cardProperties,
},

View File

@ -41,7 +41,7 @@
.templates-list {
margin-right: 32px;
min-width: 200px;
width: 300px;
max-height: 500px;
overflow-y: auto;

View File

@ -100,6 +100,8 @@ describe('components/boardTemplateSelector/boardTemplateSelector', () => {
{id: 'global-id-5'},
],
dateDisplayPropertyId: 'global-id-5',
isTemplate: true,
templateVer: 2,
},
}],
},

View File

@ -40,6 +40,10 @@
position: relative;
display: none;
right: -8px;
.DeleteIcon {
padding-top: 3px;
}
}
}

View File

@ -127,6 +127,8 @@ describe('components/boardTemplateSelector/boardTemplateSelectorItem', () => {
cardProperties: [groupProperty],
dateDisplayPropertyId: 'global-id-5',
columnCalculations: {},
isTemplate: true,
templateVer: 2,
},
}

View File

@ -38,7 +38,7 @@ const BoardTemplateSelectorItem = React.memo((props: Props) => {
>
<span className='template-icon'>{template.fields.icon}</span>
<span className='template-name'>{template.title}</span>
{template.workspaceId !== '0' &&
{!template.fields.templateVer &&
<div className='actions'>
<IconButton
icon={<DeleteIcon/>}