2022-04-12 17:41:32 +00:00
|
|
|
<!--
|
|
|
|
// Copyright © 2022 Hardcore Engineering Inc.
|
|
|
|
//
|
|
|
|
// Licensed under the Eclipse Public License, Version 2.0 (the "License");
|
|
|
|
// you may not use this file except in compliance with the License. You may
|
|
|
|
// obtain a copy of the License at https://www.eclipse.org/legal/epl-2.0
|
|
|
|
//
|
|
|
|
// Unless required by applicable law or agreed to in writing, software
|
|
|
|
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
//
|
|
|
|
// See the License for the specific language governing permissions and
|
|
|
|
// limitations under the License.
|
|
|
|
-->
|
|
|
|
<script lang="ts">
|
2022-09-21 08:08:25 +00:00
|
|
|
import { IssueStatus } from '@hcengineering/tracker'
|
2022-07-05 05:00:54 +00:00
|
|
|
import IssueStatusIcon from './IssueStatusIcon.svelte'
|
2022-04-12 17:41:32 +00:00
|
|
|
|
2023-03-22 10:08:19 +00:00
|
|
|
export let value: IssueStatus | undefined
|
|
|
|
export let size: 'small' | 'medium' = 'small'
|
2023-04-23 17:37:24 +00:00
|
|
|
export let kind: 'list-header' | undefined = undefined
|
|
|
|
export let colorInherit: boolean = false
|
|
|
|
export let accent: boolean = false
|
2023-03-29 09:35:00 +00:00
|
|
|
export let inline: boolean = false
|
2022-04-12 17:41:32 +00:00
|
|
|
</script>
|
|
|
|
|
|
|
|
{#if value}
|
2023-04-23 17:37:24 +00:00
|
|
|
<div class="flex-presenter cursor-default" style:color={'inherit'}>
|
2023-04-04 06:11:49 +00:00
|
|
|
{#if !inline}
|
2023-04-25 16:11:50 +00:00
|
|
|
<IssueStatusIcon {value} {size} on:accent-color />
|
2022-06-24 12:36:08 +00:00
|
|
|
{/if}
|
2023-04-23 17:37:24 +00:00
|
|
|
<span
|
|
|
|
class="overflow-label"
|
|
|
|
class:ml-2={!inline}
|
|
|
|
class:list-header={kind === 'list-header'}
|
|
|
|
class:colorInherit
|
|
|
|
class:fs-bold={accent}
|
|
|
|
>
|
2022-06-24 12:36:08 +00:00
|
|
|
{value.name}
|
|
|
|
</span>
|
|
|
|
</div>
|
2022-04-12 17:41:32 +00:00
|
|
|
{/if}
|
2023-04-23 17:37:24 +00:00
|
|
|
|
|
|
|
<style lang="scss">
|
|
|
|
.list-header:not(.colorInherit) {
|
|
|
|
color: var(--theme-content-color);
|
|
|
|
}
|
|
|
|
.list-header.colorInherit {
|
|
|
|
color: inherit;
|
|
|
|
}
|
|
|
|
</style>
|