Conversation
- Added `height` prop to `TextArea` and `BaseInput` components. - The `height` prop controls the `min-height` of the textarea. - Supports both `Number` (pixels) and `String` (with units) values. - Defaults to 120px if not provided. - Updated unit tests and documentation. - Incremented package version to 3.155.3. Co-authored-by: lucasn4s <17988272+lucasn4s@users.noreply.github.com>
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
Greptile SummaryEsta PR adiciona a prop
Confidence Score: 5/5PR segura para merge — todos os achados são sugestões de qualidade (P2) sem impacto funcional. Todos os problemas encontrados são P2: redundância de estilo e edge case improvável com src/components/BaseInput.vue — aplicação dupla de min-height (CSS v-bind + inline style) merece atenção para limpeza do código.
|
| Filename | Overview |
|---|---|
| src/components/BaseInput.vue | Adiciona prop height e atualiza inputMinHeight; aplica min-height duas vezes (CSS v-bind + inline style), criando redundância. |
| src/components/TextArea.vue | Adiciona prop height que é repassada ao CdsBaseInput via v-bind="{...$attrs, ...props}" — implementação simples e correta. |
| src/tests/BaseInput.spec.js | Adiciona dois testes que verificam a aplicação correta do min-height para número e string — cobertura adequada. |
| src/tests/Textarea.spec.js | Adiciona teste que verifica o repasse do height ao CdsBaseInput — correto. |
| src/tests/snapshots/Textarea.spec.js.snap | Snapshot atualizado para refletir o novo style="min-height: 120px;" no textarea — consistente com a mudança. |
| docs/components/forms/text-area.md | Documenta o novo height no playground — correto. |
| docs/.docgen/components-metadata.json | Metadados atualizados automaticamente via npm run generate:docs — correto. |
| package.json | Versão bumpeada de 3.155.2 para 3.155.3 (patch) — adequado para uma nova prop não-breaking. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A["TextArea.vue\nheight prop"] -->|"v-bind spreads props"| B["BaseInput.vue\nheight prop recebida"]
B --> C{"inputMinHeight\ncomputed"}
C -->|"type !== 'textarea'"| D["retorna 'auto'"]
C -->|"!height (null/falsy)"| E["retorna '120px' (padrão)"]
C -->|"height é Number"| F["retorna `${height}px`"]
C -->|"height é String"| G["retorna height as-is"]
E --> H["Aplicado via CSS v-bind()\n(linha 666)"]
F --> H
G --> H
E --> I["Aplicado via :style inline\n(linha 68) ⚠️ redundante"]
F --> I
G --> I
H -->|"sobrescrito por"| I
Reviews (1): Last reviewed commit: "feat(TextArea): add height prop to contr..." | Re-trigger Greptile
Remove estilo duplicado
- Added `height` prop to `TextArea` and `BaseInput`. - Implemented `min-height` control using `v-bind` in SCSS. - Supports numeric (pixels) and string values. - Updated unit tests to verify computed property logic. - Updated snapshots and documentation. - Version bumped to 3.155.3. Co-authored-by: lucasn4s <17988272+lucasn4s@users.noreply.github.com>
This change introduces a new
heightprop to theTextAreacomponent, allowing users to specify a starting (minimum) height for the input field.Key changes:
heightprop.heightprop and updated theinputMinHeightcomputed property to apply the style to the textarea element.src/tests/Textarea.spec.jsandsrc/tests/BaseInput.spec.jsto ensure the prop is correctly passed and applied.docs/components/forms/text-area.mdto include the new prop in the playground.package.jsonversion to3.155.3.docs/.docgen/components-metadata.jsonvianpm run generate:docs.PR created automatically by Jules for task 13734789671786383417 started by @lucasn4s