403Webshell
Server IP : 80.87.202.40  /  Your IP : 216.73.216.169
Web Server : Apache
System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64
User : bitrix ( 600)
PHP Version : 8.2.27
Disable Function : NONE
MySQL : OFF |  cURL : ON |  WGET : ON |  Perl : ON |  Python : OFF |  Sudo : ON |  Pkexec : ON
Directory :  /home/bitrix/ext_www/rospirotorg.ru/bitrix/js/im/view/element/attach/src/types/

Upload File :
current_dir [ Writeable] document_root [ Writeable]

 

Command :


[ Back ]     

Current File : /home/bitrix/ext_www/rospirotorg.ru/bitrix/js/im/view/element/attach/src/types/user.js
/**
 * Bitrix Messenger
 * Vue component
 *
 * User (Attach type)
 *
 * @package bitrix
 * @subpackage im
 * @copyright 2001-2019 Bitrix
 */

import "./user.css";
import { AttachLinks } from "../mixin/attachLinks";

export const AttachTypeUser =
{
	property: 'USER',
	name: 'bx-im-view-element-attach-user',
	component:
	{
		mixins: [
			AttachLinks
		],
		props:
		{
			config: {type: Object, default: {}},
			color: {type: String, default: 'transparent'},
		},
		methods:
		{
			getAvatarType(element)
			{
				if (element.AVATAR)
				{
					return '';
				}

				let avatarType = 'user';

				if (element.AVATAR_TYPE === 'CHAT')
				{
					avatarType = 'chat';
				}
				else if (element.AVATAR_TYPE === 'BOT')
				{
					avatarType = 'bot';
				}

				return 'bx-im-element-attach-type-user-avatar-type-'+avatarType;
			}
		},
		//language=Vue
		template: `
			<div class="bx-im-element-attach-type-user">
				<template v-for="(element, index) in config.USER">
					<div class="bx-im-element-attach-type-user-body">
						<div class="bx-im-element-attach-type-user-avatar">
							<div :class="['bx-im-element-attach-type-user-avatar-type', getAvatarType(element)]" :style="{backgroundColor: element.AVATAR? '': color}">
								<img v-if="element.AVATAR" 
									v-bx-lazyload
									class="bx-im-element-attach-type-user-avatar-source"
									:data-lazyload-src="element.AVATAR"
								/>
							</div>
						</div>
						<a
							v-if="element.LINK"
							:href="element.LINK" 
							class="bx-im-element-attach-type-user-name"
							target="_blank"
							@click="openLink({element: element, event: $event})"
						>
							{{element.NAME}}
						</a>
						<span v-else @click.prevent="openLink({element: element, event: $event})">
							{{element.NAME}}
						</span>
					</div>
				</template>
			</div>
		`
	},
};

Youez - 2016 - github.com/yon3zu
LinuXploit