mirror of
https://github.com/hcengineering/platform.git
synced 2026-09-12 04:37:44 +02:00
UBERF-6464: update activity mentions display (#5339)
This commit is contained in:
@@ -1,37 +0,0 @@
|
||||
<!--
|
||||
// Copyright © 2024 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">
|
||||
export let label: string
|
||||
</script>
|
||||
|
||||
<button class="hulyToDoLine-reference flex-row-top flex-no-shrink flex-gap-2" on:click>
|
||||
<div class="hulyToDoLine-icon">
|
||||
<slot name="icon" />
|
||||
</div>
|
||||
<span class="hulyToDoLine-label overflow-label font-medium-12 text-left max-w-20 secondary-textColor">
|
||||
{label}
|
||||
</span>
|
||||
<slot />
|
||||
</button>
|
||||
|
||||
<style lang="scss">
|
||||
button {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
text-align: left;
|
||||
border: none;
|
||||
outline: none;
|
||||
}
|
||||
</style>
|
||||
@@ -14,28 +14,11 @@
|
||||
-->
|
||||
<script lang="ts">
|
||||
import type { Document } from '@hcengineering/document'
|
||||
import { Icon, IconWithEmoji, getPlatformColorDef, themeStore } from '@hcengineering/ui'
|
||||
import document from '@hcengineering/document'
|
||||
import view from '@hcengineering/view'
|
||||
import ToDoReference from '../ToDoReference.svelte'
|
||||
import { DocReferencePresenter } from '@hcengineering/view-resources'
|
||||
|
||||
export let value: Document
|
||||
export let inline: boolean = false
|
||||
export let disabled: boolean = false
|
||||
export let withoutSpace: boolean = true
|
||||
|
||||
$: icon = value.icon === view.ids.IconWithEmoji ? IconWithEmoji : value.icon ?? document.icon.Document
|
||||
$: iconProps =
|
||||
value.icon === view.ids.IconWithEmoji
|
||||
? { icon: value.color }
|
||||
: {
|
||||
fill: value.color !== undefined ? getPlatformColorDef(value.color, $themeStore.dark).icon : 'currentColor'
|
||||
}
|
||||
</script>
|
||||
|
||||
<ToDoReference label={value.name} on:click>
|
||||
<svelte:fragment slot="icon">
|
||||
<Icon size="small" {icon} {iconProps} />
|
||||
</svelte:fragment>
|
||||
<DocReferencePresenter {value} on:click>
|
||||
<slot />
|
||||
</ToDoReference>
|
||||
</DocReferencePresenter>
|
||||
|
||||
@@ -1,20 +1,10 @@
|
||||
<script lang="ts">
|
||||
import { Issue } from '@hcengineering/tracker'
|
||||
import { IssueStatusIcon } from '@hcengineering/tracker-resources'
|
||||
import { statusStore } from '@hcengineering/view-resources'
|
||||
import ToDoReference from '../ToDoReference.svelte'
|
||||
import { DocReferencePresenter } from '@hcengineering/view-resources'
|
||||
|
||||
export let value: Issue
|
||||
export let inline: boolean = false
|
||||
export let disabled: boolean = false
|
||||
export let withoutSpace: boolean = true
|
||||
|
||||
$: status = $statusStore.byId.get(value.status)
|
||||
</script>
|
||||
|
||||
<ToDoReference label={value.identifier} on:click>
|
||||
<svelte:fragment slot="icon">
|
||||
<IssueStatusIcon size="small" value={status} space={value.space} />
|
||||
</svelte:fragment>
|
||||
<DocReferencePresenter {value} on:click>
|
||||
<slot />
|
||||
</ToDoReference>
|
||||
</DocReferencePresenter>
|
||||
|
||||
Reference in New Issue
Block a user