46 Commits

Author SHA1 Message Date
19ec41c965 chore: sync with main 2023-05-16 10:26:41 -04:00
7b7e05aa69 fix(datetime-button): log error if non-datetime instance is passed (#27456)
Issue number: N/A

---------

<!-- Please do not submit updates to dependencies unless it fixes an
issue. -->

<!-- Please try to limit your pull request to one type (bugfix, feature,
etc). Submit multiple pull requests if needed. -->

## What is the current behavior?
<!-- Please describe the current behavior that you are modifying. -->

An issue was filed in
https://github.com/ionic-team/ionic-framework/issues/27452 where the
`presentation` property was not being respected. The problem ended up
being that the ID passed to `ion-datetime-button` was not associated
with an `ion-datetime` instance, so it did not pick up on the
`presentation` property. I think we can handle this better by logging an
error if the ID passed does not belong to an `ion-datetime`.

## What is the new behavior?
<!-- Please describe the behavior or changes that are being added by
this PR. -->

- Log an error if the ID passed to `ion-datetime-button` exists but does
not belong to an `ion-datetime` instance.

## Does this introduce a breaking change?

- [ ] Yes
- [x] No

<!-- If this introduces a breaking change, please describe the impact
and migration path for existing applications below. -->


## Other information

<!-- Any other information that is important to this PR such as
screenshots of how the component looks before and after the change. -->
2023-05-12 15:15:50 +00:00
10d2c75f8d Merge remote-tracking branch 'origin/main' into chore/sync-with-main-5-3 2023-05-03 13:38:03 -04:00
945624c0db test(datetime-button): migrate to generators (#27307)
Issue number: N/A

---------

<!-- Please refer to our contributing documentation for any questions on
submitting a pull request, or let us know here if you need any help:
https://ionicframework.com/docs/building/contributing -->

<!-- Some docs updates need to be made in the `ionic-docs` repo, in a
separate PR. See
https://github.com/ionic-team/ionic-framework/blob/main/.github/CONTRIBUTING.md#modifying-documentation
for details. -->

<!-- Please do not submit updates to dependencies unless it fixes an
issue. -->

<!-- Please try to limit your pull request to one type (bugfix, feature,
etc). Submit multiple pull requests if needed. -->

## What is the current behavior?
<!-- Please describe the current behavior that you are modifying. -->

Datetime button tests use the legacy syntax

## What is the new behavior?
<!-- Please describe the behavior or changes that are being added by
this PR. -->

- Datetime button tests use the generator syntax

## Does this introduce a breaking change?

- [ ] Yes
- [x] No

<!-- If this introduces a breaking change, please describe the impact
and migration path for existing applications below. -->


## Other information

<!-- Any other information that is important to this PR such as
screenshots of how the component looks before and after the change. -->
2023-04-27 20:54:53 +00:00
4826a3d9f5 test(config): introduce legacy and modern playwright projects (#27228)
Issue number: N/A

---------

<!-- Please refer to our contributing documentation for any questions on
submitting a pull request, or let us know here if you need any help:
https://ionicframework.com/docs/building/contributing -->

<!-- Some docs updates need to be made in the `ionic-docs` repo, in a
separate PR. See
https://github.com/ionic-team/ionic-framework/blob/main/.github/CONTRIBUTING.md#modifying-documentation
for details. -->

<!-- Please do not submit updates to dependencies unless it fixes an
issue. -->

<!-- Please try to limit your pull request to one type (bugfix, feature,
etc). Submit multiple pull requests if needed. -->

This is the first PR to introduce the infrastructure required to add
test generators to the Ionic Framework project. This PR introduces the
file name changes necessary to support two playwright configs, so I
recommend reviewing the PR by commit:


1e5012cea1

- Created a `playwright.config-legacy.ts` file and updates
`package.json`.
- Running `npm run test.e2e` will run the generator tests, and running
`npm run test.e2e.legacy` will run the legacy tests.


4fe8de7df7

- Updates the GitHub Action scripts to run both the modern and legacy
E2E tests. I added command modifiers to avoid collisions with output
directories.


e8bcfaf926

- Updates `*.e2e.ts` files to have the legacy format name:
`*.e2e-legacy.ts`. This naming scheme is required for the two Playwright
configs to pull in the correct files. When migrating tests to
generators, team members will rename the file to remove the `-legacy`
part.


5bf196c36d
(warning: lots of files!)

- Updates the `*.e2e.ts-snapshots` directories to have the legacy format
name: `*.e2e-legacy.ts-snapshots`. The screenshot directory in
Playwright is generated based on the test file name which is why we are
updating the screenshot directory. When migrating tests to generators,
team members will rename the directory to remove the `-legacy` part.

## Does this introduce a breaking change?

- [ ] Yes
- [x] No

<!-- If this introduces a breaking change, please describe the impact
and migration path for existing applications below. -->


## Other information

<!-- Any other information that is important to this PR such as
screenshots of how the component looks before and after the change. -->
2023-04-26 18:27:17 +00:00
0ac451998c test(many): do not await page.locator (#27267)
Issue number: N/A

---------

<!-- Please refer to our contributing documentation for any questions on
submitting a pull request, or let us know here if you need any help:
https://ionicframework.com/docs/building/contributing -->

<!-- Some docs updates need to be made in the `ionic-docs` repo, in a
separate PR. See
https://github.com/ionic-team/ionic-framework/blob/main/.github/CONTRIBUTING.md#modifying-documentation
for details. -->

<!-- Please do not submit updates to dependencies unless it fixes an
issue. -->

<!-- Please try to limit your pull request to one type (bugfix, feature,
etc). Submit multiple pull requests if needed. -->

## What is the current behavior?
<!-- Please describe the current behavior that you are modifying. -->

`page.locator` is synchronous, but we were `await`ing the calls:
https://playwright.dev/docs/api/class-page#page-locator

We were also doing `page.locator(...).click()` when we can just do
`page.click([selector])` directly,

## What is the new behavior?
<!-- Please describe the behavior or changes that are being added by
this PR. -->

- Removes `await` usage from `page.locator`
- Removes `page.locator().click()` usage in favor of `page.click()`

## Does this introduce a breaking change?

- [ ] Yes
- [x] No

<!-- If this introduces a breaking change, please describe the impact
and migration path for existing applications below. -->


## Other information

<!-- Any other information that is important to this PR such as
screenshots of how the component looks before and after the change. -->
2023-04-25 12:26:17 +00:00
0a0345a84a refactor(many): use utils import (#27160) 2023-04-12 13:25:14 -07:00
eb10a2e5f6 chore(): sync with main 2023-03-24 14:37:39 -04:00
53af005122 chore(deps-dev): bump @playwright/test from 1.31.2 to 1.32.0 in /core (#27003) 2023-03-23 12:44:59 -04:00
3f888c0928 chore(): sync with main 2023-03-03 12:00:21 -05:00
89a465c9ea chore(playwright): update to v1.31.1 (#26869) 2023-03-02 13:43:29 -05:00
799871e95d chore(): sync with main 2023-02-22 10:00:56 -05:00
804e54e5ca test(many): migrate to new toHaveScreenshot API (#26797) 2023-02-16 11:37:29 -05:00
e028d13a1b chore(many): import types from source path (#26718) 2023-02-02 11:40:51 -05:00
b78b454e08 revert(): revert base components feature (#26692)
The Ionic Framework team would like to re-evaluate our approach to improving customization options when building mobile applications. We are looking at other solutions that a) make customizing an app UI easier and b) are applicable to a broader set of developers.
2023-01-30 11:52:36 -05:00
18f109c7da feat(base-components): add ability to remove ios and md theme (#26669) 2023-01-24 16:18:35 -05:00
d54b9dfdc0 chore(): sync with main 2022-12-20 10:44:26 -05:00
bd05fccf58 test(config): update to playwright 1.29.0 (#26388) 2022-12-20 09:26:51 -05:00
88e7ee985d chore(): sync with main 2022-12-09 12:37:06 -05:00
3481c44b2f test(many): add await to async asserts (#26456) 2022-12-09 10:36:19 -05:00
b18a193684 chore(): sync with main 2022-12-08 12:39:38 -05:00
fcfbcdbc20 fix(datetime): md highlight does not clip at start or end of month (#26366)
Resolves #24891
2022-12-06 13:43:44 -05:00
acb12b36ee Merge remote-tracking branch 'origin/main' into chore/sync-7.0-with-main-12-05-22 2022-12-05 11:25:10 -05:00
1a5ee2f30f test(config): remove playwright diff threshold (#26405) 2022-12-05 11:08:59 -05:00
f06e438db3 test(config): reduce diff threshold to 0.0025 (#26387) 2022-12-01 10:26:14 -05:00
df6064e986 test(config): reduce playwright pixel threshold to 0.005 (#26375) 2022-11-30 12:25:49 -05:00
ce2e37b1a1 fix(angular): null values are not converted to falsy value (#26341)
BREAKING CHANGE:

Datetime:

Passing the empty string to the `value` property will now error as it is not a valid ISO-8601 value.

Angular:

`null` values on form components will no longer be converted to the empty string (`''`) or `false`. This impacts `ion-checkbox`, `ion-datetime`, `ion-input`, `ion-radio`, `ion-radio-group`, ion-range`, `ion-searchbar`, `ion-segment`, `ion-select`, `ion-textarea`, and `ion-toggle`.
2022-11-23 13:03:13 -05:00
c149b42d0b Merge remote-tracking branch 'origin/main' into sync-7-11-15-22 2022-11-15 15:40:21 -05:00
5a701b5b42 test(playwright): reduce diff threshold to 0.01 (#26279) 2022-11-14 15:14:09 -05:00
f13ddcaf47 fix(datetime): fonts now render consistently (#26281) 2022-11-14 12:55:14 -05:00
b470a307e3 chore(): sync with main 2022-11-08 13:13:46 -05:00
bb005956ea fix(overlays): presenting an overlay does not create nested elements (#26154)
Resolves #26117
2022-11-02 16:57:22 -04:00
3fb4caf21f fix(datetime): do not report timezone in ionChange (#26183)
resolves #25577

BREAKING CHANGE:

Datetime no longer incorrectly reports the time zone when `value` is updated. Datetime does not manage time zones, so any time zone information provided is ignored.
2022-10-31 15:03:14 -04:00
92d7bd5d7d Merge remote-tracking branch 'origin/main' into sync-feature-10-21 2022-10-21 14:36:30 -04:00
51ab5f67b5 fix(datetime): empty string is treated as no value (#26131)
resolves #26116
2022-10-17 15:01:27 -04:00
cc2af202a9 feat(datetime): ionChange will only emit from user committed changes (#26083)
resolves #20873 resolves #24452

BREAKING CHANGE

- `ionChange` is no longer emitted when the `value` property of `ion-datetime` is modified externally. `ionChange` is only emitted from user committed changes, such as clicking or tapping a date.

- Datetime no longer automatically adjusts the `value` property when passed an array and `multiple="false"`. Developers should update their apps to ensure they are using the API correctly.
2022-10-11 17:17:52 -04:00
5242dad473 chore(): add updated snapshots 2022-09-30 17:28:13 +00:00
25e6fe92b1 chore(): sync with main 2022-09-30 12:29:00 -04:00
fd658514b5 test(config): lower pixel diff threshold to 0.02 (#26010) 2022-09-26 12:33:27 -04:00
12b8a0cab8 test(config): lower pixel diff threshold to 0.03 (#26004) 2022-09-26 08:48:12 -04:00
21b1ca5041 test(config): lower pixel diff threshold to 0.04 (#26002) 2022-09-23 17:35:25 -04:00
a56a4a9c05 feat(datetime-button): support multiple date selection (#25971) 2022-09-21 11:29:56 -04:00
8a1b3c5f30 feat(datetime): add header text to multiple selection; improve header consistency between modes (#25817)
Co-authored-by: Sean Perkins <sean@ionic.io>
2022-08-29 11:18:45 -05:00
ae6aa0cb8e chore(eslint): add strict-boolean-expressions rule (#25768) 2022-08-23 11:50:02 -05:00
79c65dc382 test(playwright): add new utilities for skipping tests (#25758) 2022-08-16 09:18:42 -04:00
499733105e feat(datetime-button): add button for displaying datetime in overlays (#25655)
resolves #24316
2022-07-27 09:47:02 -04:00