Skip to content

inputtext: стилизация, сторисы, токены#171

Open
khaliulin wants to merge 55 commits intostorybook-updatefrom
form/InputText
Open

inputtext: стилизация, сторисы, токены#171
khaliulin wants to merge 55 commits intostorybook-updatefrom
form/InputText

Conversation

@khaliulin
Copy link
Copy Markdown
Collaborator

No description provided.

@khaliulin khaliulin requested a review from Skosov March 25, 2026 07:16
Comment thread src/plugins/prime/theme3.0/components/css/inputtext.ts Outdated
Comment thread src/plugins/prime/theme3.0/css.ts Outdated
Comment thread figma-console-mcp Outdated
Comment thread src/plugins/prime/theme3.0/css.ts Outdated
@Skosov
Copy link
Copy Markdown
Member

Skosov commented Apr 6, 2026

Решить конфликты

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

почему этот файл вообще в этом ПР редактируется?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Skosov пришёл через merge storybook-update, не относится к InputText напрямую — мёрж 88a15ea

Comment thread src/plugins/prime/theme3.0/css.ts
argTypes: {
size: {
control: 'select',
options: ['small', 'medium', 'large', 'xlarge'],
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

прайм не умеет в xlarge, нужен какой-то коммент, что нужно использовать зарезервированный класс

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Skosov добавлен комментарий в description argType 18b56d1

@khaliulin
Copy link
Copy Markdown
Collaborator Author

@Skosov резолв конфиктов 75dcebb

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

навзание файла видимо прошлое вернулось

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

а, ну в целом файл просто остался почему-то

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

нужно удалить файл

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Skosov удалён неактуальный PBlockInputTextClear ff2985d

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Skosov готово ff2985d

import { IconX } from '@tabler/icons-vue';

const props = withDefaults(
defineProps<{
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

почему исчезло наследование от базового текст инпута?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Skosov PBlockInputText: наследование InputTextProps, v-bind для проброса пропсов 8fb7169

Comment on lines +10 to +14
invalid?: boolean;
disabled?: boolean;
readonly?: boolean;
placeholder?: string;
fluid?: boolean;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

нет смысла описывать, если наследоваться

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Skosov PBlockInputText: наследование InputTextProps, v-bind для проброса пропсов 8fb7169

Comment thread src/primeBlocks/PBlockInputText/PBlockInputText.vue Outdated
import { IconX } from '@tabler/icons-vue';
import { computed } from 'vue';

interface PBlockInputTextProps extends /* @vue-ignore */ InputTextProps {
Copy link
Copy Markdown
Member

@Skosov Skosov Apr 24, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

не вижу прокидывания пропса has-floatlabel

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Skosov PBlockInputText: проп hasFloatlabel с инкапсулированным FloatLabel ad0d0a2

Comment thread src/primeBlocks/PBlockInputText/PBlockInputText.vue Outdated
Copy link
Copy Markdown
Member

@Skosov Skosov Apr 24, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

неактуальный файл

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Skosov PBlockInputText: удалён неактуальный svg/x.svg 96695a7

}

&__required {
color: var(--p-red-500);
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@khaliulin коммент для меня. Проверить как еще можно читать токены прайма на стороне оберток


&__required {
color: var(--p-red-500);
margin-left: 2px;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

точно ок в пикселях?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Skosov PBlockInputText: токен spacing вместо пикселей cc65cfa

</script>

<template>
<FloatLabel v-if="hasFloatlabel" variant="in">
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

в ds не планируется других вариантов использования флоатов?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Skosov на момент разработки – нет.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ок, но я бы в сториз тогда описал, что возможно использование FloatLabel и PBlockInputText напрямую

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Skosov добавлено описание прямого использования FloatLabel + PBlockInputText в stories 67e2262

Comment on lines +78 to +100
<IconField
v-else
class="p-block-inputtext"
:class="{ 'p-block-inputtext--fluid': fluid }"
>
<InputText
v-bind="attrs"
:modelValue="modelValue"
:fluid="fluid"
:size="size === 'xlarge' ? undefined : size"
:class="{ 'p-inputtext-xlg': size === 'xlarge' }"
@update:modelValue="onUpdateModelValue($event as string)"
/>
<InputIcon
v-show="showClear && modelValue"
class="p-block-inputtext__icon"
@click.stop="onClear"
>
<slot name="clear-icon">
<IconX :size="14" />
</slot>
</InputIcon>
</IconField>
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Дублирование кода, вынести в подкомпонент, переиспользовать в двух случаях

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Skosov PBlockInputText: подкомпонент PBlockInputTextField, устранение дублирования 8af21ba

@click.stop="onClear"
>
<slot name="clear-icon">
<IconX :size="14" />
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

в ремах нельзя указать?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Skosov PBlockInputTextField: размер иконки в rem (1rem = iconSize токен) 825ea8a

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants