Proposal: new QDialog helper commands
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 35/100
- issue の種類
- 機能追加
- 明瞭さ
- おおむね明確
- 活発さ
- 停滞
- 技術スタック
- cypress, typescript
- 領域
- testing-qa
調査の方向性
Start with the existing withinDialog entry point and the portal-related commands that use Cypress.$('body'). Check how Cypress resolves cy.root(), cy.window(), and cy.document() inside and outside within contexts. Done means the proposed dialog helpers cover escape, backdrop, persistent, and convenience use cases, including seamless and backdrop-free dialogs.
索引モデルが issue の本文から書いたものです。
説明
We're considering adding some new helper commands related to QDialog
closeDialogViaEscKey
function closeDialogViaEscKey () {
// Official way to escape `within` context
// https://docs.cypress.io/api/commands/within#Temporarily-escape
return cy.root().closest('body').type('{esc}')
}
Limitation: this only works in withinDialog context, as when using it outside it .root() will yeld "html" tag and Cypress won't be able to find anything with .closest('body') since it only searches upwards
We should find a way to make it work both inside and outside a within context
I tried with cy.window() and cy.document() already, which I recalled worked fine in the past, but it seems like they changed that behavior
Maybe by using the Cypress.$('body') shortcut that we already use in portal-related commands?
Even if it's an internal and undocumented feature AFAIK
closeDialogViaBackdrop
function closeDialogViaBackdrop () {
return cy.get('.q-dialog__backdrop').click({ force: true })
}
assertPersistentDialogExists
function assertPersistentDialogExists () {
cy.get('.q-dialog').should('not.have.attr', 'aria-modal', 'false')
}
This should be called automatically after the callback function of withinDialog completes, if persistent is set to true
Unluckily, this actually doesn't work all the times and has a few limitations we need to address
In particular, it doesn't address seamless dialogs use case (which always have 'aria-modal' equal to false) and dialogs without backdrop, which are equally not considered modals, and thus have 'aria-modal' equal to false
We should find a more reliable way to check for persistent dialogs, possibly even add a custom dedicated class into Quasar core for QDialog
withinPersistentDialog
Just a convenience method to avoid the more verbose form of withinDialog
Before
cy.withinDialog({
persistent: true,
fn: () => {
// ...
}
})
After
cy.withinPersistentDialog(() => {
// ...
})
- 主要言語
- TypeScript
- スター
- 184
- フォーク
- 67
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
quasarframework/quasar-testing のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
-
難易度 4/5 3〜5日 初心者へのやさしさ 35/100
-
難易度 4/5 3〜5日 初心者へのやさしさ 35/100
-
Proposal: Improve portal dependent components (e.g. QSelect , QButtonGroup etc) testing experienceオープン
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
-
enhancement
難易度 3/5 1〜2日 初心者へのやさしさ 42/100
quasarframework/quasar-testing の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
tenstorrent/ttnn-visualizer#2526 ·
メンテナーはふだん 1 日以内に返信
-
trySessionCache calls /get-session twice when minting session_data (cache miss or expired cookie)オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
neondatabase/neon-js#301 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 2 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
tashfeenahmed/freellmapi#2305 ·
メンテナーはふだん 1 日以内に返信