Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add new onboarding tours #200

Merged
merged 49 commits into from
Apr 18, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
384e09f
add data-testid
dvflorianengertsberger Nov 30, 2021
e464ad3
add id for dataset searchbox
dvvanessastoiber Dec 13, 2021
5879b89
add data-testid to react select components
dvflorianengertsberger Jan 4, 2022
5a31382
Merge remote-tracking branch 'origin/develop' into cypress-testing
dvvanessastoiber Jan 17, 2022
452b83e
fix lint
dvvanessastoiber Jan 17, 2022
d81f7a9
fix react select error
dvflorianengertsberger Jan 18, 2022
5a28b07
Merge remote-tracking branch 'origin/develop' into cypress-testing
dvvanessastoiber Mar 22, 2022
761c42f
update dist
dvvanessastoiber Mar 22, 2022
d22cb38
Merge remote-tracking branch 'origin/develop' into cypress-testing
dvvanessastoiber May 30, 2022
caec0d4
update dist
dvvanessastoiber May 30, 2022
e71f24e
rename for constistency
dvvanessastoiber Jun 7, 2022
617bc8c
Merge remote-tracking branch 'origin/develop' into cypress-testing
dvvanessastoiber Jun 21, 2022
3946d4e
update dist
dvvanessastoiber Jun 21, 2022
b944ee0
Merge remote-tracking branch 'origin/develop' into cypress-testing
dvvanessastoiber Jun 30, 2022
ee11bbc
Fix typings
thinkh Jun 30, 2022
fbc855a
add index.js
dvvanessastoiber Jul 19, 2022
2867237
fix setup
dvvanessastoiber Jul 19, 2022
e0d7459
update imports and function calls
dvvanessastoiber Jul 20, 2022
2fd228f
update video
dvvanessastoiber Jul 22, 2022
1e07eb1
Refactored cy related files for Cypress v10
dvmichaelpeterseil Aug 9, 2022
992a58d
Test Duplicant Tour
dvmichaelpeterseil Aug 16, 2022
de915c9
Halfway with AssessBCCellLines tour
dvmichaelpeterseil Aug 22, 2022
1443bda
Almost done AssessBCCellLines tour
dvmichaelpeterseil Aug 22, 2022
3f9ca9f
Merge remote-tracking branch 'origin/develop' into sorry_cypress_testing
dvmichaelpeterseil Aug 22, 2022
ff6fb0e
Merge remote-tracking branch 'origin/sorry_cypress_testing' into dvMi…
dvmichaelpeterseil Aug 22, 2022
f23554c
Update Dist
dvmichaelpeterseil Aug 22, 2022
5eab43a
Fixed Hidden Modal Bug
dvmichaelpeterseil Aug 29, 2022
f52de57
AssessBCCellLines Tour Complete (Unpolished)
dvmichaelpeterseil Aug 30, 2022
38fbf9e
AssessBCCellLine Tour Complete (Polished)
dvmichaelpeterseil Sep 2, 2022
cbfdd78
Prep PredictionTP53Tour and slight refactoring
dvmichaelpeterseil Sep 2, 2022
9efaeff
Updated Tour2
dvmichaelpeterseil Sep 5, 2022
d4184c1
Updated Tour2
dvmichaelpeterseil Sep 5, 2022
01a3229
Nearly complete DrugTargetDiscoveryTour
dvmichaelpeterseil Sep 27, 2022
0372957
Merge remote-tracking branch 'origin/develop' into dvMike/1365_Additi…
dvmichaelpeterseil Feb 15, 2023
3ad9fe0
Update gitignore
dvmichaelpeterseil Feb 15, 2023
bcbf227
Merge remote-tracking branch 'origin/develop' into dvMike/1365_Additi…
dvmichaelpeterseil Mar 13, 2023
c97bf08
Stash Tour Testing
dvmichaelpeterseil Mar 13, 2023
e2efaf6
Updated tours
dvmichaelpeterseil Mar 23, 2023
ebb9ddb
Add dependency
oltionchampari Mar 23, 2023
5fbb05d
Added blockers to stabilize tour
dvmichaelpeterseil Mar 23, 2023
f433320
Merge branch 'dvMike/1365_Additional-Tours' of github.com:Caleydo/tdp…
dvmichaelpeterseil Mar 23, 2023
fb08f9f
Functional completion of the new tours
dvmichaelpeterseil Mar 30, 2023
f3329a9
Shortened names and descriptions for spacing
dvmichaelpeterseil Apr 3, 2023
787e1c0
Updated tour preview images
dvmichaelpeterseil Apr 3, 2023
1b54d1e
Merge branch 'develop' into dvMike/1365_Additional-Tours
oltionchampari Apr 5, 2023
2fad12f
chore: add missing dist files
thinkh Apr 6, 2023
edbcfc1
Minor fixes and improvments
oltionchampari Apr 7, 2023
ba09b7c
Dist
oltionchampari Apr 7, 2023
963e5c2
fix: add hi-res tour preview images
thinkh Apr 11, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Added blockers to stabilize tour
  • Loading branch information
dvmichaelpeterseil committed Mar 23, 2023
commit 5fbb05d7796f9359cdff8f88603b6fe294a56d47
38 changes: 19 additions & 19 deletions src/phovea.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1092,7 +1092,7 @@ export default function (registry) {
},
{
factory: 'createTour',
name: 'Prediction of TP53 Mutation Status',
name: 'Prediction of TP53 Mutation Status (WIP)',
description: 'This case study summarizes another analysis session, this time involving the prediction of the mutation status for TP53.',
preview() {
return import('./assets/previews/expression.jpg'); // TODO update preview image
Expand All @@ -1103,24 +1103,24 @@ export default function (registry) {
},
);

registry.push(
'tdpTour',
'ordinoDrugTargetDiscoveryTour',
function () {
return import('./tours').then((t) => t.DrugTargetDiscoveryTour);
},
{
factory: 'createTour',
name: 'Drug Target Discovery',
description: '??? Add description here.',
preview() {
return import('./assets/previews/expression.jpg'); // TODO update preview image
},
multiPage: true,
level: 'beginner',
canJumpAround: false,
},
);
// registry.push(
// 'tdpTour',
// 'ordinoDrugTargetDiscoveryTour',
// function () {
// return import('./tours').then((t) => t.DrugTargetDiscoveryTour);
// },
// {
// factory: 'createTour',
// name: 'Drug Target Discovery',
// description: '??? Add description here.',
// preview() {
// return import('./assets/previews/expression.jpg'); // TODO update preview image
// },
// multiPage: true,
// level: 'beginner',
// canJumpAround: false,
// },
// );
/// #endif

registry.push(
Expand Down
39 changes: 23 additions & 16 deletions src/tours/AssessBCCellLinesTour.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
// import {ToursSection} from 'ordino';
import selectEvent from 'react-select-event';
import { IStep, Tour, TourUtils } from 'tdp_core';

export class AssessBCCellLinesTour {
Expand Down Expand Up @@ -39,7 +40,7 @@ export class AssessBCCellLinesTour {
html: `<p>Here they choose between the three entity types <i>'Cell Lines'</i>, <i>'Tissue Samples'</i>, and <i>'Genes'</i>.</p>
<p>In this example they choose to work with a list of genes.</p>`,
placement: 'centered',
preAction: () => TourUtils.waitFor('#ordino_dataset_tab > .ordino-scrollspy-container .genes-dataset > .card').then(() => TourUtils.wait(600)),
preAction: () => TourUtils.waitFor('#ordino_dataset_tab > .ordino-scrollspy-container .genes-dataset > .card').then(() => TourUtils.wait(1000)),
postAction: () => TourUtils.click('.ordino-dataset.genes-dataset .session-tab > li:first-child'),
},
{
Expand All @@ -57,7 +58,7 @@ export class AssessBCCellLinesTour {
selector: '.le.le-multi.lineup-engine',
placement: 'centered',
html: `The information is presented in a tabular format. Additionally to the gene ID, a set of columns containing some basic information is shown by default.`,
preAction: () => TourUtils.waitFor('.le.le-multi.lineup-engine', Infinity).then(() => TourUtils.wait(1500)),
preAction: () => TourUtils.waitFor('.le-tr:nth-of-type(1)', Infinity),
},
{
selector: '.lu-side-panel-wrapper .lu-adder > button',
Expand All @@ -77,7 +78,7 @@ export class AssessBCCellLinesTour {
{
selector: '.modal.show .col > .select3',
placement: 'centered',
preAction: () => TourUtils.waitFor('.modal.show').then(() => TourUtils.wait(150)),
preAction: () => TourUtils.waitFor('.modal.show', Infinity).then(() => TourUtils.wait(150)),
html: `Now they select the cell line 'HCC1954' &hellip;`,
postAction: () => {
TourUtils.setValueAndTrigger('.modal.show .select3 input.select2-search__field', 'HCC1954;', 'input');
Expand All @@ -101,15 +102,16 @@ export class AssessBCCellLinesTour {
selector: '.le [data-col-id="col8"] .lu-action-sort',
placement: 'centered',
html: `They want to sort by this newly added column, so they click on the sort button in the column header.`,
preAction: () => TourUtils.waitFor('.le [data-col-id="col8"] .lu-action-sort'),
preAction: () => TourUtils.waitFor('.le-tr:nth-of-type(1) [title="1.83"]', Infinity),
postAction: () => {
TourUtils.click('.le [data-col-id="col8"] .lu-action-sort');
},
},
{
selector: ['[data-index="0"].le-tr, [data-index="14"].le-tr'],
// selector: ['[data-index="0"].le-tr, [data-index="14"].le-tr'], // Bug: It highlights the selectors before waiting for the preAction
placement: 'centered',
html: `After sorting by this column, the analyst observes that about 15 genes on chromosome 17 are affected by a large genomic amplification.`,
preAction: () => TourUtils.waitFor('.le-tr:nth-of-type(1) [title="8.00"]', Infinity),
},
{
selector: '.lu-side-panel-wrapper .lu-adder > button',
Expand All @@ -120,18 +122,19 @@ export class AssessBCCellLinesTour {
TourUtils.click('.lu-side-panel-wrapper .lu-adder > button');
TourUtils.click('[data-testid=lu-adder-div] > .lu-search > .lu-search-list > :nth-child(2) > ul > :nth-child(1) > span');
TourUtils.toggleClass('.lu-adder.once', 'once', false);
TourUtils.waitFor('.modal.show').then(() => {
TourUtils.waitFor('.modal.show').then(async () => {
TourUtils.setValueAndTrigger('.modal.show .select3 input.select2-search__field', 'HCC1954;', 'input');
TourUtils.setValueAndTrigger('.show .col > select', 'expression-tpm', 'change');
TourUtils.wait(1000).then(() => TourUtils.click('.modal.show .modal-footer button[type=submit]'));
await TourUtils.wait(1000);
TourUtils.click('.modal.show .modal-footer button[type=submit]');
});
},
},
{
selector: '.lu-side-panel-wrapper .lu-adder > button',
html: `They also add a column with a Gene Sensitivity Score (a measure of importance for cell survival) for HCC1954.`,
placement: 'centered',
preAction: () => TourUtils.waitFor('.le header [data-col-id="col9"]').then(() => TourUtils.wait(500)),
preAction: () => TourUtils.waitFor('.le-tr:nth-of-type(1) [title="5324.86"]', Infinity),
postAction: () => {
TourUtils.click('.lu-side-panel-wrapper .lu-adder > button');
},
Expand All @@ -156,7 +159,7 @@ export class AssessBCCellLinesTour {
html: `<p>In an effort to improve the depletion score's readability, they decide to invert the linear scaling.</p>
<p>To do this, they click on the three dots for more column options.</p>`,
placement: 'centered',
preAction: TourUtils.waitForSelector,
preAction: () => TourUtils.waitFor('.le-tr:nth-of-type(1) [title="−2.75"]', Infinity),
postAction: TourUtils.clickSelector,
},
{
Expand Down Expand Up @@ -185,6 +188,7 @@ export class AssessBCCellLinesTour {
<p>Observe: Combining the columns highlights the importance of ERBB2.</p>
<p>It is therefore probably the most relevant gene within this amplified genomic region.</p>`,
placement: 'centered',
allowUserInteraction: true,
},
{
selector: '[data-index="0"]',
Expand All @@ -206,8 +210,9 @@ export class AssessBCCellLinesTour {
TourUtils.click('.lu-side-panel-wrapper .lu-adder > button');
TourUtils.click('[data-testid=lu-adder-div] > .lu-search > .lu-search-list > :nth-child(2) > ul > :nth-child(2) > span');
TourUtils.toggleClass('.lu-adder.once', 'once', false);
TourUtils.waitFor('.show .modal-body form > div:nth-child(1) .row:nth-child(1) div:nth-child(1) select').then(() => {
TourUtils.waitFor('.show .modal-body form > div:nth-child(1) .row:nth-child(1) div:nth-child(1) select').then(async () => {
TourUtils.setValueAndTrigger('.show .modal-body form > div:nth-child(1) .row:nth-child(1) div:nth-child(1) select', 'tumortype', 'change');
await TourUtils.wait(500);
TourUtils.setValueAndTrigger(
'.show .modal-body form > .col-sm-12:nth-child(1) .row:nth-child(1) .row:nth-child(1) > div:nth-child(2) select',
'breast carcinoma',
Expand All @@ -225,13 +230,14 @@ export class AssessBCCellLinesTour {
selector: '.lu-side-panel-wrapper .lu-adder > button',
html: `2. A column with the gene copy number distribution for breast cancer cell lines in boxplot format`,
placement: 'centered',
preAction: () => TourUtils.waitFor('.le header [data-col-id="col11"]'),
preAction: () => TourUtils.waitFor('.le-tr:nth-of-type(1) [title="890.37"]', Infinity),
postAction: () => {
TourUtils.click('.lu-side-panel-wrapper .lu-adder > button');
TourUtils.click('[data-testid=lu-adder-div] > .lu-search > .lu-search-list > :nth-child(2) > ul > :nth-child(2) > span');
TourUtils.toggleClass('.lu-adder.once', 'once', false);
TourUtils.waitFor('.show .modal-body form > div:nth-child(1) .row:nth-child(1) div:nth-child(1) select').then(() => {
TourUtils.waitFor('.show .modal-body form > div:nth-child(1) .row:nth-child(1) div:nth-child(1) select').then(async () => {
TourUtils.setValueAndTrigger('.show .modal-body form > div:nth-child(1) .row:nth-child(1) div:nth-child(1) select', 'tumortype', 'change');
await TourUtils.wait(500);
TourUtils.setValueAndTrigger(
'.show .modal-body form > .col-sm-12:nth-child(1) .row:nth-child(1) .row:nth-child(1) > div:nth-child(2) select',
'breast carcinoma',
Expand All @@ -249,13 +255,14 @@ export class AssessBCCellLinesTour {
selector: '.lu-side-panel-wrapper .lu-adder > button',
html: `3. A column with the gene amplification frequency (>4) across all breast cancer cell lines`,
placement: 'centered',
preAction: () => TourUtils.waitFor('.le header [data-col-id="col12"]'),
preAction: () => TourUtils.waitFor('.le-tr:nth-of-type(1) .lu-renderer-boxplot', Infinity),
postAction: () => {
TourUtils.click('.lu-side-panel-wrapper .lu-adder > button');
TourUtils.click('[data-testid=lu-adder-div] > .lu-search > .lu-search-list > :nth-child(2) > ul > :nth-child(2) > span');
TourUtils.toggleClass('.lu-adder.once', 'once', false);
TourUtils.waitFor('.show .modal-body form > div:nth-child(1) .row:nth-child(1) div:nth-child(1) select').then(() => {
TourUtils.waitFor('.show .modal-body form > div:nth-child(1) .row:nth-child(1) div:nth-child(1) select').then(async () => {
TourUtils.setValueAndTrigger('.show .modal-body form > div:nth-child(1) .row:nth-child(1) div:nth-child(1) select', 'tumortype', 'change');
await TourUtils.wait(500);
TourUtils.setValueAndTrigger(
'.show .modal-body form > .col-sm-12:nth-child(1) .row:nth-child(1) .row:nth-child(1) > div:nth-child(2) select',
'breast carcinoma',
Expand All @@ -277,7 +284,7 @@ export class AssessBCCellLinesTour {
selector: '.le.le-multi.lineup-engine',
html: `Observe: They notice that ERBB2 is amplified in almost 25% of all assessed breast cancer cell lines. Further, it is highly expressed.`,
placement: 'centered',
preAction: () => TourUtils.waitFor('.le header [data-col-id="col13"]'),
preAction: () => TourUtils.waitFor('.le-tr:nth-of-type(1) [title="0.25"]', Infinity),
},
{
selector: '[data-index="0"] .lu-renderer-selection',
Expand Down Expand Up @@ -416,7 +423,7 @@ export class AssessBCCellLinesTour {
<p>HCC1954 has the highest ERBB2 amplification among BRCA1 mutated cell lines.</p>
<p>HCC1569 has the highest ERBB2 amplification among BRCA2 mutated cell lines.</p>`,
placement: 'centered',
preAction: () => TourUtils.waitFor('[data-testid="viewWrapper-1"] .le header [data-col-id="col8"]'),
preAction: () => TourUtils.waitFor('.le-tr:nth-of-type(1) [data-id="col8"][data-renderer="categorical"]'),
},
{
selector: '',
Expand Down
2 changes: 1 addition & 1 deletion src/tours/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ export * from './AddColumnToGeneListTour';
export * from './StartMenuTour';
export * from './AssessBCCellLinesTour';
export * from './PredictionTP53Tour';
export * from './DrugTargetDiscoveryTour';
// export * from './DrugTargetDiscoveryTour';