docs: archive add-hero-signup-form #70
No files matched your search
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -63,7 +63,7 @@ A page save SHALL be refused with the offending field path, writing nothing, whe
|
||||
|
||||
### Requirement: Block References Stay Inside The Company
|
||||
|
||||
A block's image SHALL be an image of the page's company, and a FORM block's event SHALL be an event of the page's company. Otherwise the save SHALL be refused on that field.
|
||||
A block's image SHALL be an image of the page's company, and the event of a FORM block or of a HERO block that names one SHALL be an event of the page's company. Otherwise the save SHALL be refused on that field.
|
||||
|
||||
#### Scenario: Another company's event
|
||||
|
||||
@@ -71,6 +71,12 @@ A block's image SHALL be an image of the page's company, and a FORM block's even
|
||||
- **WHEN** INS staff save a FORM block pointing at `CV Roadshow`
|
||||
- **THEN** the save is refused on that block's event field
|
||||
|
||||
#### Scenario: Another company's event in a hero
|
||||
|
||||
- **GIVEN** event `CV Roadshow` belongs to CV
|
||||
- **WHEN** INS staff save a HERO block whose event is `CV Roadshow`
|
||||
- **THEN** the save is refused on that block's event field
|
||||
|
||||
### Requirement: Page Content Cannot Run Scripts
|
||||
|
||||
A button SHALL have both a label and a link or neither. The link SHALL start with a single `/`, `https://`, `mailto:`, `tel:`, or `#` plus a valid block link name. A save SHALL be refused when RICH_TEXT or IMAGE_TEXT HTML holds a `script` element, an `on*` attribute or a `javascript:` URL. The public page SHALL also sanitise that HTML against an allow-list. HTML blocks are exempt: they only run sealed.
|
||||
@@ -570,3 +576,32 @@ When a save or publish is refused on a block field, the editor SHALL select that
|
||||
- **GIVEN** a page from the Event sign-up template
|
||||
- **WHEN** staff save without choosing the form's event
|
||||
- **THEN** the form section is selected and outlined and the panel shows the message at the Event field
|
||||
|
||||
### Requirement: Hero With A Sign-Up Form
|
||||
|
||||
A HERO block MAY name an event. When it does, the hero SHALL show Co-Lite's sign-up form for that event in a card beside its heading, text and button on wide screens, and below them on narrow screens. The hero's form SHALL follow every rule of the FORM block (see "The Form Block Registers For An Event" and "The Form Block Closes With Its Event"). A HERO block without an event SHALL show no form.
|
||||
|
||||
#### Scenario: Sign up from the hero
|
||||
|
||||
- **GIVEN** page `/p/INS/hotel-technology` has a HERO block whose event is `INS website enquiries`
|
||||
- **WHEN** a new visitor submits the form in the hero from a URL with `utm_source=facebook`
|
||||
- **THEN** a new lead and an event lead with source Web page, no salesperson and UTM source `facebook` are created
|
||||
|
||||
#### Scenario: Hero form closes with its event
|
||||
|
||||
- **GIVEN** the HERO block's event ended yesterday
|
||||
- **WHEN** a visitor opens the page
|
||||
- **THEN** the hero still shows its heading and text, and its form area says sign-up is closed
|
||||
|
||||
#### Scenario: Hero without an event
|
||||
|
||||
- **WHEN** a visitor opens a page whose HERO block names no event
|
||||
- **THEN** the hero shows no form
|
||||
- **AND** a submit addressed to that block is refused as not found
|
||||
|
||||
#### Scenario: Pick the hero's event in the editor
|
||||
|
||||
- **GIVEN** staff editing a page with a HERO block
|
||||
- **WHEN** they pick `INS website enquiries` under the hero's sign-up form setting
|
||||
- **THEN** the canvas shows the form card beside the hero text
|
||||
- **AND** choosing "No form" removes it
|
||||
Reference in new issue
Block a user