-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add HTML syntax highlighted editing to the template editor.
- Refactor codeflask HTML editor into a standalone html-editor component. - Replace the plaintext box in the template editor with html-editor. - Replace codeflask in the campaign editor with the new html-editor. - Refactor templates Cypress tests to test the new editor. - Refactor campaigns Cypress tests to test the new editor and also test switching between different editors and content formats.
- Loading branch information
Showing
10 changed files
with
109 additions
and
125 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -70,9 +70,10 @@ type subOptin struct { | |
|
||
var ( | ||
dummySubscriber = models.Subscriber{ | ||
Email: "[email protected]", | ||
Name: "Demo Subscriber", | ||
UUID: dummyUUID, | ||
Email: "[email protected]", | ||
Name: "Demo Subscriber", | ||
UUID: dummyUUID, | ||
Attribs: models.SubscriberAttribs{"city": "Bengaluru"}, | ||
} | ||
|
||
subQuerySortFields = []string{"email", "name", "created_at", "updated_at"} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -30,7 +30,7 @@ describe('Lists', () => { | |
|
||
it('Checks individual subscribers in lists', () => { | ||
const subs = [{ listID: 1, email: '[email protected]' }, | ||
{ listID: 2, email: '[email protected]' }]; | ||
{ listID: 2, email: '[email protected]' }]; | ||
|
||
// Click on each list on the lists page, go the the subscribers page | ||
// for that list, and check the subscriber details. | ||
|
@@ -94,16 +94,17 @@ describe('Lists', () => { | |
cy.get('select[name=optin]').select(o); | ||
cy.get('input[name=tags]').type(`tag${n}{enter}${t}{enter}${o}{enter}`); | ||
cy.get('button[type=submit]').click(); | ||
cy.wait(200); | ||
|
||
// Confirm the addition by inspecting the newly created list row. | ||
const tr = `tbody tr:nth-child(${n + 1})`; | ||
cy.get(`${tr} td[data-label=Name]`).contains(name); | ||
cy.get(`${tr} td[data-label=Type] [data-cy=type-${t}]`); | ||
cy.get(`${tr} td[data-label=Type] [data-cy=optin-${o}]`); | ||
cy.get(`${tr} td[data-label=Type] .tag[data-cy=type-${t}]`); | ||
cy.get(`${tr} td[data-label=Type] .tag[data-cy=optin-${o}]`); | ||
cy.get(`${tr} .tags`) | ||
.should('contain', `tag${n}`) | ||
.and('contain', t) | ||
.and('contain', o); | ||
.and('contain', t, { matchCase: false }) | ||
.and('contain', o, { matchCase: false }); | ||
|
||
n++; | ||
}); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.