mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2026-03-13 10:22:08 +08:00
fix(textarea): inherit tabindex to inner textarea (#26945)
resolves #26944
This commit is contained in:
14
core/src/components/input/test/input.spec.ts
Normal file
14
core/src/components/input/test/input.spec.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
import { newSpecPage } from '@stencil/core/testing';
|
||||
import { Input } from '../input';
|
||||
|
||||
it('should inherit attributes', async () => {
|
||||
const page = await newSpecPage({
|
||||
components: [Input],
|
||||
html: '<ion-input title="my title" tabindex="-1" data-form-type="password"></ion-input>',
|
||||
});
|
||||
|
||||
const nativeEl = page.body.querySelector('ion-input input');
|
||||
expect(nativeEl.getAttribute('title')).toBe('my title');
|
||||
expect(nativeEl.getAttribute('tabindex')).toBe('-1');
|
||||
expect(nativeEl.getAttribute('data-form-type')).toBe('password');
|
||||
});
|
||||
Reference in New Issue
Block a user