From f0ec82453cc56298d43c5716d11e1d463c620fcf Mon Sep 17 00:00:00 2001 From: Rowanne Kabalan Date: Wed, 1 Nov 2023 20:42:43 +0000 Subject: [PATCH 1/4] Remove deprecated recipe atom --- app/util/AtomElementBuilders.scala | 2 - public/images/typeicons/recipe-icon.svg | 1 - public/js/components/AtomEdit/AtomEdit.js | 3 - .../AtomEdit/CustomEditors/RecipeEditor.js | 85 -- .../CustomEditors/RecipeFields/Ingredient.js | 193 ----- .../RecipeFields/IngredientList.js | 38 - .../CustomEditors/RecipeFields/Servings.js | 131 ---- public/js/constants/atomData.js | 11 +- public/js/constants/recipeData.js | 737 ------------------ public/js/util/atomDataExtractors.js | 1 - 10 files changed, 1 insertion(+), 1201 deletions(-) delete mode 100644 public/images/typeicons/recipe-icon.svg delete mode 100644 public/js/components/AtomEdit/CustomEditors/RecipeEditor.js delete mode 100644 public/js/components/AtomEdit/CustomEditors/RecipeFields/Ingredient.js delete mode 100644 public/js/components/AtomEdit/CustomEditors/RecipeFields/IngredientList.js delete mode 100644 public/js/components/AtomEdit/CustomEditors/RecipeFields/Servings.js delete mode 100644 public/js/constants/recipeData.js diff --git a/app/util/AtomElementBuilders.scala b/app/util/AtomElementBuilders.scala index 337aa9ef..7de12411 100644 --- a/app/util/AtomElementBuilders.scala +++ b/app/util/AtomElementBuilders.scala @@ -3,7 +3,6 @@ package util import com.gu.contentatom.thrift.AtomData.Chart import com.gu.contentatom.thrift.atom.chart._ import com.gu.contentatom.thrift.atom.cta.CTAAtom -import com.gu.contentatom.thrift.atom.recipe.{RecipeAtom, Tags => RecipeTags, Time => RecipeTime} import com.gu.contentatom.thrift.atom.qanda.{QAndAAtom, QAndAItem} import com.gu.contentatom.thrift.atom.profile.ProfileAtom import com.gu.contentatom.thrift.atom.guide.GuideAtom @@ -45,7 +44,6 @@ object AtomElementBuilders { val defaultAtoms: Map[AtomType, AtomData] = Map( AtomType.Cta -> AtomData.Cta(CTAAtom("-")), - AtomType.Recipe -> AtomData.Recipe(RecipeAtom(title, RecipeTags(), RecipeTime())), AtomType.Explainer -> AtomData.Explainer(ExplainerAtom(title, "-", DisplayType.Flat)), AtomType.Qanda -> AtomData.Qanda(QAndAAtom(Some("Q&A"), None, QAndAItem(None, "Body"))), AtomType.Guide -> AtomData.Guide(GuideAtom(None, None, Nil)), diff --git a/public/images/typeicons/recipe-icon.svg b/public/images/typeicons/recipe-icon.svg deleted file mode 100644 index a2a20dfb..00000000 --- a/public/images/typeicons/recipe-icon.svg +++ /dev/null @@ -1 +0,0 @@ -recipe-icon \ No newline at end of file diff --git a/public/js/components/AtomEdit/AtomEdit.js b/public/js/components/AtomEdit/AtomEdit.js index 1b194f50..92a57bef 100644 --- a/public/js/components/AtomEdit/AtomEdit.js +++ b/public/js/components/AtomEdit/AtomEdit.js @@ -1,7 +1,6 @@ import React from 'react'; import {PropTypes} from 'prop-types'; import {CTAEditor} from './CustomEditors/CTAEditor'; -import {RecipeEditor} from './CustomEditors/RecipeEditor'; import {QAndAEditor} from './CustomEditors/QAndAEditor'; import {GuideEditor} from './CustomEditors/GuideEditor'; import {ProfileEditor} from './CustomEditors/ProfileEditor'; @@ -80,8 +79,6 @@ class AtomEdit extends React.Component { switch (atomType) { case ("cta"): return ; - case ("recipe"): - return ; case ("qanda"): return ; case ("guide"): diff --git a/public/js/components/AtomEdit/CustomEditors/RecipeEditor.js b/public/js/components/AtomEdit/CustomEditors/RecipeEditor.js deleted file mode 100644 index 72fa8a75..00000000 --- a/public/js/components/AtomEdit/CustomEditors/RecipeEditor.js +++ /dev/null @@ -1,85 +0,0 @@ -import React from 'react'; -import {PropTypes} from 'prop-types'; - -import {ManagedForm, ManagedField} from '../../ManagedEditor'; -import FormFieldNumericInput from '../../FormFields/FormFieldNumericInput'; -import FormFieldArrayWrapper from '../../FormFields/FormFieldArrayWrapper'; -import FormFieldTextInput from '../../FormFields/FormFieldTextInput'; -import FormFieldImageSelect from '../../FormFields/FormFieldImageSelect'; -import FormFieldMultiSelect from '../../FormFields/FormFieldMultiSelect'; -import {RecipeServings} from './RecipeFields/Servings'; -import {IngredientList} from './RecipeFields/IngredientList'; -import * as recipeData from '../../../constants/recipeData'; - -export class RecipeEditor extends React.Component { - - static propTypes = { - atom: PropTypes.shape({ - type: PropTypes.string, - id: PropTypes.string - }).isRequired, - onUpdate: PropTypes.func.isRequired, - onFormErrorsUpdate: PropTypes.func, - config: PropTypes.shape({ - gridUrl: PropTypes.string.isRequired - }).isRequired - } - - render () { - return ( - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ); - } -} diff --git a/public/js/components/AtomEdit/CustomEditors/RecipeFields/Ingredient.js b/public/js/components/AtomEdit/CustomEditors/RecipeFields/Ingredient.js deleted file mode 100644 index 7cda395c..00000000 --- a/public/js/components/AtomEdit/CustomEditors/RecipeFields/Ingredient.js +++ /dev/null @@ -1,193 +0,0 @@ -import React from 'react'; -import {PropTypes} from 'prop-types'; -import {ManagedForm, ManagedField} from '../../../ManagedEditor'; -import FormFieldTextInput from '../../../FormFields/FormFieldTextInput'; -import FormFieldSelectBox from '../../../FormFields/FormFieldSelectBox'; -import FormFieldNumericInput from '../../../FormFields/FormFieldNumericInput'; - -export class Ingredient extends React.Component { - - static propTypes = { - fieldLabel: PropTypes.string, - fieldName: PropTypes.string, - fieldValue: PropTypes.shape({ - item: PropTypes.string, - comment: PropTypes.string, - quantity: PropTypes.number, - quantityRange: PropTypes.shape({ - from: PropTypes.number, - to: PropTypes.number - }), - unit: PropTypes.string - }), - fieldPlaceholder: PropTypes.string, - onUpdateField: PropTypes.func, - onFormErrorsUpdate: PropTypes.func - }; - - updateQuantity = (newQuantity, newQuantityRange) => { - this.props.onUpdateField(Object.assign({}, this.props.fieldValue, { - quantity: newQuantity, - quantityRange: newQuantityRange - })); - } - - updateUnit = (newValue) => { - this.props.onUpdateField(Object.assign({}, this.props.fieldValue, { - unit: newValue - })); - } - - render () { - return ( - - - - - - - - - - ); - } -} - - -class Quantity extends React.Component { - - static propTypes = { - quantity: PropTypes.number, - quantityRange: PropTypes.shape({ - from: PropTypes.number, - to: PropTypes.number - }), - updateQuantity: PropTypes.func.isRequired, - unit: PropTypes.string, - updateUnit: PropTypes.func.isRequired - }; - - constructor(props) { - super(props); - - this.state = { - isRange: !props.quantityRange - }; - } - - toggleRange = () => { - this.setState({ - isRange: !this.state.isRange - }); - - //Reset Quantity and do the right thing with the current value - if (this.props.quantity) { // We have an absolute... copy to from - this.props.updateQuantity(undefined, { - from: this.props.quantity - }); - } else if (this.props.quantityRange && this.props.quantityRange.from) { - // we have a from, copy to absolute - this.props.updateQuantity(this.props.quantityRange.from, undefined); - } else { - this.props.updateQuantity(undefined, undefined); - } - } - - updateFrom = (value) => { - const newRange = Object.assign({}, this.props.quantityRange, { - from: value - }); - this.props.updateQuantity(undefined, newRange); - } - - updateTo = (value) => { - const newRange = Object.assign({}, this.props.quantityRange, { - to: value - }); - this.props.updateQuantity(undefined, newRange); - } - - updateAbsoluteQuantity = (value) => { - this.props.updateQuantity(value, undefined); - } - - - renderRange() { - return ( -
-
- -
-
- -
-
- -
-
- ); - } - - renderNonRange() { - return ( -
-
- -
-
- -
-
- ); - } - - render () { - return ( -
- - Range? - {this.state.isRange ? this.renderRange() : this.renderNonRange()} -
- ); - } -} - -class Units extends React.Component { - unitTypes = ['cup', 'g', 'kg', 'oz', 'lb', 'bottle', 'floz', 'l', 'litre', 'ml', 'tsp', 'tbsp', 'dsp', 'bunch', 'cm', 'can', 'clove', 'dash', 'grating', 'handful', 'packet', 'piece', 'pinch', 'sheet', 'sprig', 'stick']; - - static propTypes = { - fieldValue: PropTypes.string, - updateUnit: PropTypes.func.isRequired - }; - - updateIngredientUnit = (value) => { - this.props.updateUnit(value); - } - - render () { - return ( - - ); - } -} diff --git a/public/js/components/AtomEdit/CustomEditors/RecipeFields/IngredientList.js b/public/js/components/AtomEdit/CustomEditors/RecipeFields/IngredientList.js deleted file mode 100644 index 645aeaca..00000000 --- a/public/js/components/AtomEdit/CustomEditors/RecipeFields/IngredientList.js +++ /dev/null @@ -1,38 +0,0 @@ -import React from 'react'; -import {PropTypes} from 'prop-types'; -import {ManagedForm, ManagedField} from '../../../ManagedEditor'; -import {Ingredient} from './Ingredient'; -import FormFieldTextInput from '../../../FormFields/FormFieldTextInput'; -import FormFieldArrayWrapper from '../../../FormFields/FormFieldArrayWrapper'; - -export class IngredientList extends React.Component { - - static propTypes = { - fieldLabel: PropTypes.string, - fieldName: PropTypes.string, - fieldValue: PropTypes.shape({ - title: PropTypes.string, - ingredients: PropTypes.array - }), - fieldPlaceholder: PropTypes.string, - onUpdateField: PropTypes.func, - onFormErrorsUpdate: PropTypes.func - }; - - render () { - return ( -
- - - - - - - - - - -
- ); - } -} diff --git a/public/js/components/AtomEdit/CustomEditors/RecipeFields/Servings.js b/public/js/components/AtomEdit/CustomEditors/RecipeFields/Servings.js deleted file mode 100644 index dedbab5a..00000000 --- a/public/js/components/AtomEdit/CustomEditors/RecipeFields/Servings.js +++ /dev/null @@ -1,131 +0,0 @@ -import React from 'react'; -import {PropTypes} from 'prop-types'; - -import FormFieldRadioButtons from '../../../FormFields/FormFieldRadioButtons'; -import FormFieldNumericInput from '../../../FormFields/FormFieldNumericInput'; -import FormFieldSelectBox from '../../../FormFields/FormFieldSelectBox'; -import {logError} from '../../../../util/logger'; - -export class RecipeServings extends React.Component { - - static propTypes = { - fieldLabel: PropTypes.string, - fieldName: PropTypes.string, - fieldValue: PropTypes.shape({ - type: PropTypes.string, - from: PropTypes.number, - to: PropTypes.number, - unit: PropTypes.string - }), - fieldPlaceholder: PropTypes.string, - onUpdateField: PropTypes.func - }; - - servingTypes = [ - { - value: 'serves', - name: 'Serves a specfic number of people (e.g. serves 4 people)', - hasUnits: false - }, - { - value: 'makes', - name: 'Makes a specific number (e.g. 3 mince pies)', - hasUnits: false - }, - { - value: 'quantity', - name: 'Produces a specific quantity (e.g. produces 1kg of icing)', - hasUnits: true - } - ] - - units = [ - "kilograms", "litres" - ]; - - updateServingType = (fieldValue) => { - const servingType = this.servingTypes.find(servingType => servingType.name === fieldValue); - - if (!servingType) { - logError("Couldn't find serving type matching value", fieldValue); - return; - } - - this.props.onUpdateField({ - type: servingType.value - }); - } - - updateFromField = (fieldValue) => { - const existingData = this.props.fieldValue || {}; - - this.props.onUpdateField(Object.assign({}, existingData, { - from: fieldValue - })); - } - - updateToField = (fieldValue) => { - const existingData = this.props.fieldValue || {}; - - this.props.onUpdateField(Object.assign({}, existingData, { - to: fieldValue - })); - } - - updateUnits = (fieldValue) => { - const existingData = this.props.fieldValue || {}; - - this.props.onUpdateField(Object.assign({}, existingData, { - units: fieldValue - })); - } - - getActiveServingType = () => { - const existingData = this.props.fieldValue || {}; - return this.servingTypes.find(servingType => servingType.value === existingData.type); - } - - shouldShowUnitsPicker = () => { - const currentServingType = this.getActiveServingType(); - return currentServingType && currentServingType.hasUnits; - } - - render () { - return ( -
-

Servings

- servingType.name)} - fieldValue={this.getActiveServingType() ? this.getActiveServingType().name : ""}/> - -
-
- -
-
- -
- - { this.shouldShowUnitsPicker() ? -
- -
: false - } -
- -
- ); - } -} diff --git a/public/js/constants/atomData.js b/public/js/constants/atomData.js index 679729bf..ade619af 100644 --- a/public/js/constants/atomData.js +++ b/public/js/constants/atomData.js @@ -17,13 +17,6 @@ export const cta = { description: 'A call to action designed for use in GLabs Hosted Content', }; -export const recipe = { - type: 'recipe', - fullName: 'Recipe', - description: - 'Structured recipes for better website presentation within articles', -}; - export const quiz = { type: 'quiz', fullName: 'Quiz', @@ -93,7 +86,6 @@ export const audio = { }; export const allAtomTypes = [ - recipe, qa, guide, profile, @@ -107,7 +99,6 @@ export const allAtomTypes = [ commonsDivision, ]; export const workshopEditableAtomTypes = [ - recipe, qa, guide, profile, @@ -121,7 +112,7 @@ export const workshopEditableAtomTypes = [ export const snippetAtomTypes = [qa, guide, profile, timeline]; export const legacyAtomTypes = [explainer]; -export const experimentalAtomTypes = [commonsDivision, recipe]; +export const experimentalAtomTypes = [commonsDivision]; export function getNonEditableAtomTypes() { return allAtomTypes.filter(atomType => { diff --git a/public/js/constants/recipeData.js b/public/js/constants/recipeData.js deleted file mode 100644 index bf2161d7..00000000 --- a/public/js/constants/recipeData.js +++ /dev/null @@ -1,737 +0,0 @@ -export const cuisineList = [ - 'African', - 'American', - 'Asian', - 'BBQ', - 'British', - 'Caribbean', - 'Chinese', - 'French', - 'Greek', - 'Indian', - 'Irish', - 'Italian', - 'Japanese', - 'Korean', - 'Lebanese', - 'Mediterranean', - 'Mexican', - 'Moroccan', - 'Nordic', - 'North African', - 'Persian', - 'Polish', - 'Portuguese', - 'South American', - 'Spanish', - 'Thai', - 'Turkish', - 'Vietnamese' -]; - -export const categoryList = [ - 'Baking', - 'Barbecue', - 'Breakfast', - 'Budget', - 'Canapes', - 'Dessert', - 'Dinner', - 'Dinner party', - 'Drinks and cocktails', - 'Healthy eating', - 'Lunch', - 'Main course', - 'Picnic', - 'Salads', - 'Sandwich', - 'Sides', - 'Soup', - 'Snacks', - 'Starters' -]; - -export const celebrationList = [ - 'Baisakhi', - 'Christmas', - 'Diwali', - 'Easter', - 'Eid', - 'Halloween', - 'Hanukkah', - 'Passover', - 'Thanksgiving' -]; - -export const dietaryList = [ - 'Low sugar', - 'Low fat', - 'High fibre', - 'Nut free', - 'Gluten free', - 'Dairy free', - 'Egg free', - 'Vegetarian', - 'Vegan' -]; - -export const chefs = [ - 'Nigel Slater and Observer readers', - 'Ross Dobson', - 'Killian Fox', - 'Nico Peratinos', - 'Riad Nasr and Lee Hanson', - 'Anna Jones', - 'Joseph Trivelli', - 'Ismants Zusmanis', - 'Neneh Cherry and Andi Oliver', - 'The Guardian', - 'Katy Salter', - 'Marco Pierre White', - 'Sophia and Rob Palmer', - 'Regula Ysewijn', - 'Chloe Diski', - 'Interview by Rebecca Seal', - 'Tom Kerridge', - 'Sam Taylor', - 'Joe Trivelli', - 'Melody Moxham', - 'Interview by Dale Berning', - 'Svetlana Graudt in Moscow and Maeve Shearlaw', - 'Jamie Oliver', - 'Caroline Hart', - 'Bibi van der Zee', - 'Fiona Beckett', - 'Tori Egherman for Tehran Bureau', - 'Thomasina Miers and Fiona Beckett', - 'Clem Bastow', - 'Will Bowlby', - 'Luca Missaglia', - 'Guardian Cook', - 'Urvesh Parvais', - 'Sophie Mackenzie', - 'Kira Cochrane', - 'Richard Johnson', - 'Interview by Bibi van der Zee', - 'Rob Andrew', - 'Alain Ducasse', - 'Meera Sodha and Mina Holland', - 'Sue Quinn', - 'Annalisa Barbieri', - 'Mary Lewis', - 'René Redzepi', - 'Gill Partington', - 'Nayla Audi', - 'Phil Daoust', - 'Sybil Kapoor', - 'Molly Tait-Hyland', - 'Jane Fearnley-Whittingstall', - 'Rosie Birkett', - 'Daniel Young', - 'Folayemi Brown', - 'Alessandro Villa', - 'Samuel and Samantha Clark', - 'Kitty Travers', - 'Sara Jenkins', - 'Eleonora Galasso', - 'Tarek Malouf', - 'Lisa Allen', - 'Ed Fitzpatrick', - 'Jacob Fodio Todd', - 'Marco Pierre-White', - 'Henrietta Lovell', - 'Dale Berning Sawa', - 'Oliver Rowe', - 'Jared Brown', - 'René Madsen', - 'Homa Khaleeli', - 'The Ethicurean', - 'Gianni Albanese', - 'Interviews by Tim Lewis', - 'Brian Turner', - 'James Wragg', - 'Claus Meyer', - 'Henrietta Clancy', - 'Bryn Williams', - 'Clarissa Dickson Wright', - 'Sally Butcher', - 'Helen Graves', - 'Jack Monroe', - 'Annabel Crabb', - 'Daniel Clifford', - 'Sam Bompas and Harry Parr', - 'Thomasina Miers and Mat Follas', - 'Donna Hay', - 'Hope and Greenwood', - 'Rahila Hussain', - 'Andrew Whitley', - 'Romy Gill', - 'Chad Parkhill', - 'Galston Blackiston', - 'Lottie Muir', - 'Kate Young', - 'Giles Looker', - 'Natasha Hughes', - 'Bruno Loubet', - 'Joan H', - 'Jeff Galvin', - 'Rob Andrew of Riverford Field Kitchen', - 'David Rowles', - 'Pierre Koffmann', - 'Tomer Amedi', - 'Carol Klein', - 'Shirley Spear', - 'Amanda Grant', - 'Yotam Ottolenghi and Sami Tamimi', - 'Lily Vanilli', - 'Pablo Lopez Jarana', - 'Jeremy Lee and Fiona Beckett', - 'Yotam Ottolenghi', - 'Simon Hopkinson', - 'Interview by Phil Daoust', - 'David Thompson', - 'Sarah Raven', - 'Jacob Kenedy', - 'Hugh Fearnley-Whittinstall', - 'Lia Leendertz', - 'James Ramsden', - 'Bart van Olphen and Tom Kime', - 'Henry Dimbelby', - 'Claire Thomson and Mina Holland', - 'Robb Eadie and Nick Latham', - 'Hugh Fearnley-Whittingstall and Nikki Duffy', - 'Research by Rikke Bruntse-Dahl', - 'Angela Hartnett and Ashley Palmer-Watts', - 'Imogen Carter', - 'Marguerite Patten', - 'Emma Underwood', - 'Chris Golding', - 'Interview by Katy Salter', - 'Interview Killian Fox', - 'Carolyn Caldicott and Chris Caldicott', - 'Allegra McEvedy\'s', - 'Chris Michael in Mumbai', - 'Vicky Frost', - 'Tom Parker-Bowles', - 'Kay Bolitho', - 'Nicci Gerrard', - 'VP', - 'Suze Olbrich', - 'Sabine Durrant', - 'Lamees Ibrahim', - 'Philip Greene', - 'Thomasina Miers', - 'Andy Kerr', - 'Gregory Marchand', - 'Nigel Slater and Tim Atkin', - 'Anna Gare', - 'Peter Fuchs', - 'Trina Hahnemann', - 'Julie Nelson Rhodes', - 'Interview by Killian Fox', - 'Jason Atherton and Fiona Beckett', - 'Atul Kochhar', - 'Simon Rimmer', - 'Dan Lepard and Allegra McEvedy', - 'Nigel Sandals', - 'David Parkinson', - 'Kevin Gould', - 'Jane Baxter and Henry Dimbleby', - 'Stefano Marchetto', - 'Benjamin Pryor', - 'Alice Hart', - 'Virgilio Martinez', - 'Peter Gordon', - 'David Lebovitz', - 'Interview by Tim Lewis', - 'Alastair Hendy', - 'Simon Creasey', - 'Rob Andrews', - 'Hannah Jane Parkinson and Emma Howard', - 'Christina Tosi', - 'Angela Hartnett', - 'Mark Hix and Rosie Lovell', - 'Interview by Jay Rayner', - 'Interview by Sue Quinn', - 'Intro by Joanna Blythman and recipe by Rosie Sykes', - 'Ruth Joseph and Simon Round', - 'Mark Hix', - 'Joseph Shuldiner', - 'Nuno Mendes', - 'Vicky Bhogal', - 'Mark Fothergill', - 'Alan Yau', - 'Meera Sodha', - 'Jason King', - 'Magnus Nilsson', - 'Neil Rankin', - 'Emily Ludolf', - 'Giorgio Locatelli and Michel Roux Jr', - 'Anita Sethi', - 'Nikki Duffy', - 'Interview by Chloe Diski', - 'Lizzie Mabbott', - 'Maria Elia and Fiona Beckett', - 'Giorgio Locatelli', - 'Fuchsia Dunlop and Killian Fox', - 'Mike Robinson', - 'Observer', - 'Rob Worsley', - 'Mitch Tonks', - 'Shaun Hill', - 'Linda Tubby', - 'Preman Mohan', - 'Andy McLeish', - 'Zuza Zak', - 'Interview by Lizzie Enfield', - 'Jason Atherton', - 'Kate Percy', - 'Maureen Pogson', - 'Fraser Lewry', - 'Gérard Depardieu', - 'Marcus Wareing and Clare Smyth', - 'Dawid Samulczyk', - 'Beata Zatorska', - 'Stephen Harris', - 'Susan Smillie and Felicity Cloake', - 'Zoe Williams with Anna Jones', - 'Gavan Knox', - 'Chestnut blinis', - 'Norman Musa', - 'Annie Rigg', - 'Max Veenhuyzen', - 'Allan Jenkins', - 'Heston Blumenthal', - 'Guardian readers and Eve O\'Sullivan', - 'Tamar Adler', - 'Tamsin Blanchard', - 'Mary-Ellen McTeague', - 'Nieves Barragán Mohacho', - 'Isaac McHale and James Lowe', - 'Alaina Wong', - 'Simon Hopkinson and Matthew Harris', - 'Rachael Wass', - 'Intro by Joanna Blythman and Rosie Sykes', - 'Genevieve Taylor', - 'Adam Tomlinson', - 'Marianna Leivaditaki', - 'The Urban Rajah', - 'Gemma Baldwin', - 'Simon Difford', - 'Jeremy Lee and Sat Bains', - 'The Skint Foodie', - 'Villi Ivanova', - 'Heston Blumenthal and Ashley Palmer-Watts', - 'Paul Gayler', - 'Garry Foy', - 'Namita Panjabi', - 'Mark Sargeant and Fiona Beckett', - 'Susan Smillie', - 'Thressi Kottukapally', - 'Josceline Dimbleby', - 'Tom Kitchin', - 'Ahdaf Soueif', - 'Interview by Kevin Gould', - 'Joyce Molyneux and Gerard Baker', - 'Interview by Dale Berning Sawa', - 'Deb Perelman', - 'Henry Dimbleby with Jane Baxter', - 'Cinead McTernan', - 'Anirudh Arora and Hardeep Singh Kohli', - 'Sophie Dahl', - 'Alexis Gauthier', - 'Mark Olive', - 'The Kitchen Cooperative', - 'Shuko Oda', - 'Mary Ann Gilchrist', - 'Anna Hansen', - 'Justin McCurry in Seoul', - 'Jean Shrimpton', - 'Allegra McEvedy', - 'Fuchsia Dunlop', - 'Rebecca Seal', - 'Paul Foster', - 'Oliver Thring', - 'Nick Crispini', - 'Maria Kuehn', - 'Tom Adams', - 'Anju George', - 'Neil Perry', - 'Sam Jones', - 'Ian Burrell', - 'Valentine Warner', - 'Junya Yamasaki', - 'Rachel Roddy', - 'Ruth Rogers and Rose Gray', - 'Mitch Tonks and Fiona Beckett', - 'Hannah Miles', - 'Rosie Sykes', - 'Henry Dimbleby', - 'Rosie Reynolds', - 'Blanche Vaughan', - 'Jane Baxter and John Vincent', - 'Ruth Spivey', - 'Alex Clark', - 'Alex Bluett', - 'Word of Mouth', - 'Ching-He Huang', - 'Ben Milgate and Elvis Abrahanowicz', - 'Interview by Tamsin Blanchard', - 'Adrian Brett', - 'Lynn Calvo', - 'Andrew Wong', - 'Trine Hahnemann', - 'Miriam González Durántez', - 'Sheryl Garratt', - 'Simon Schama', - 'Ruth Rogers', - 'Henry Dimbleby and Jane Baxter', - 'Mark Sargeant', - 'The Guide', - 'José Pizarro', - 'Bee Wilson', - 'Brad McDonald', - 'Yasmin Alibhai-Brown', - 'Guardian', - 'Charlotte Done', - 'Tom Hunt', - 'Pierre Koffman', - 'Zia Basrai', - 'Jane Scotter and Harry Astley', - 'Sasha Belkovich', - 'Rachel Khoo', - 'Margot Henderson', - 'Melissa Cole', - 'Rachel Holmes', - 'Melissa and Jasmine Hemsley', - 'Interview by Tim Atkin', - 'Sophie Missing and Caroline Craig', - 'Anna Trapido', - 'Pam Corbin', - 'Kate Hawkings', - 'Dale Berning-Sawa', - 'Sam Harris', - 'Alexis Soyer', - 'Jane Baxter and John Vincent', - 'David Eyre', - 'Rosie Lovell', - 'Susanna Booth', - 'Gizzi Erskine', - 'Madhur Jaffrey', - 'Katie Caldesi', - 'Claire Thomson', - 'Imants Zusmanis', - 'Gordon Ramsay', - 'Fran Warde', - 'Gill Meller', - 'Perri Lewis', - 'Ed Smith', - 'Tamal Ray', - 'Claudia Roden', - 'Frances Somers Cocks', - 'Mary-Ellen McTague', - 'Andrew Shanahan', - 'Sonya Kidney', - 'Pete Nielsen', - 'Matt Jones', - 'John Crace', - 'Raymond Blanc', - 'Simon Rogan', - 'Richard Bertinet', - 'Edd Kimber', - 'Interview with Dale Berning', - 'James Chase', - 'Joanna Blythman and Rosie Sykes', - 'Darina Allen', - 'Oskar Kinberg', - 'Eve O\'Sullivan', - 'Signe Johansen', - 'Hugh Fearnley-Whittingstall', - 'Skye Gyngell', - 'Lorraine Pascale and Fiona Beckett', - 'Rachel Kelly', - 'Kitty Hope and Mark Greenwood', - 'Paul Levy', - 'Ben Tish', - 'Elena and Juan Mari Arzak', - 'Rose Gray and Ruth Rogers', - 'Lorraine Pascale', - 'Miss South', - 'Rick Bayless', - 'Rene Redzepi', - 'Victoria Moore', - 'Christopher Wormell', - 'Anthony Demetre', - 'Mindy Fox', - 'Richard Woods', - 'Anissa Helou', - 'Shelley McAlister', - 'Andy Connelly', - 'Harry Eastwood', - 'José Pizarro with an introduction by Allan Jenkins', - 'Claire Kelsey', - 'Natascha Mirosch', - 'David Frenkiel and Luise Vindahl', - 'Kylie Kwong', - 'Max Brearley', - 'Rachel Smith', - 'Paul Cunningham', - 'Claire Thompson', - 'Vava Berry', - 'Monica Galetti', - 'Dharmesh Lakhani', - 'Alice Holden', - 'Tim Hayward', - 'Sam and Sam Clark', - 'Boris Fishman', - 'Morwenna Ferrier', - 'John Wright', - 'Nathan Outlaw', - 'Interview by Dave Hall', - 'Andrew Pern', - 'Intervew by Eve O\'Sullivan', - 'Rachel Cooke', - 'Michael Bremner', - 'John Lanchester', - 'Sarah Brown', - 'Karam Sethi', - 'Clement Robert', - 'Dita Locatelli', - 'Florence Knight', - 'Phil Hall', - 'Richie West', - 'Roger Browning', - 'Adam Wyatt-Jones', - 'Olia Hercules', - 'Jeremy Lee', - 'Silvena Rowe and Malcolm Gluck', - 'Adam Perry Lang', - 'Clare Lattin and Tom Hill', - 'Interview by Stephen Fletcher', - 'Ali Reynolds', - 'Lee Che Liang', - 'Dave Felton', - 'Claude Bosi', - 'Mary Berry and Paul Hollywood', - 'Claire Ptak', - 'Chris Arnot', - 'MiMi Aye', - 'Justin Gellatly', - 'Robin Gill', - 'Rob Allison', - 'Dan Lepard', - 'Eduard Vasile', - 'April Bloomfield', - 'Russell Norman', - 'Sarah Percy', - 'Sabrina Ghayour', - 'Zoe Adjonyoh', - 'Paul Brown', - 'Richard Turner', - 'Jordan Bourke and Rejina Pyo', - 'Mina Holland', - 'Stéphane Reynaud', - 'Andy Hamilton', - 'Nigella Lawson', - 'Charles Phan', - 'Alex Renton', - 'Frank Boxer', - 'Guardian readers', - 'Martin Morales and the Andina team', - 'Delia Smith', - 'Peter Bayless', - 'Sabrina Ghayour interviewed by Mina Holland', - 'Helen Pidd', - 'Copperbot Bar for Chick\'n\'Sours', - 'Patrice de Villiers', - 'Vivek Singh', - 'Matthew Fort and Heston Blumenthal', - 'Jiri Majerik', - 'Kylee Newton', - 'Angela Hartnett and Neil Borthwick', - 'Christine Carroll and Jody Eddy', - 'Kate Carter', - 'Rose Elliot', - 'Caroline Craig and Sophie Missing', - 'Billy Deakin', - 'Lynn Barber', - 'Jon Henley', - 'Yotam Ottolenghi and Fiona Beckett', - 'Pablo Uribe and Rob Baines', - 'Kaushy Patel', - 'Kitty Dann', - 'Carlene Thomas-Bailey', - 'Fanny Zanotti', - 'Maria Elia', - 'Tom and Henry Herbert', - 'Sarit Packer and Itamar Srulovich', - 'Ashley Palmer-Watts', - 'Silvena Rowe', - 'Martha Swift and Lisa Thomas', - 'Sue Hornby', - 'Colman Andrews', - 'Rich Woods', - 'Sally Clarke', - 'Zoe Williams', - 'Mina Holland and Duval Timothy', - 'Camellia Panjabi', - 'Nigel Walker', - 'Lagusta Yearwood', - 'Isa Chandra Moskowitz', - 'Felicity Cloake and Guardian readers', - 'Fiona Cairns', - 'Sevtap Yüce', - 'Jack Adair Bevan', - 'Anna Moore', - 'Jeanette Edgar and Rachel Godwin', - 'Georgia Levy and Benjamin Benton', - 'Simon Majumdar', - 'Carl Brown', - 'Jane Hughes', - 'Kayla Epstein and Sarah Galo', - 'Hugh Fearnley-Whittingstall and Fiona Beckett', - 'Keith McNally', - 'Eleanor Morgan', - 'Rosamund Man and Robin Weir', - 'Tom Norrington-Davies', - 'Fergus Henderson', - 'with Dale Berning Sawa', - 'Alecia Wood', - 'Stephanie Reynaud', - 'Ruby Tandoh', - 'Rhik Samadder and Felicity Cloake', - 'Christie Dietz', - 'Nobu', - 'Ben Clark', - 'Interview by Nell Card', - 'Pino Dispinseri', - 'Cook writers', - 'Nichola Gensler', - 'Blaze Langier', - 'Trish Deseine', - 'Ollie Dabbous', - 'Matthew Evans', - 'Richard Ehrlich', - 'Bill Granger', - 'Matthew Fort', - 'Seamus MacInnes', - 'Joanna Blythman', - 'Stevie Parle', - 'Hugh-Fearnley Whittingstall', - 'Emine Saner', - 'Selin Kiazim', - 'Sandra Deeble', - 'Justin Piers Gellatly', - 'Interview by Rachel Cooke', - 'Tobie Puttock', - 'Sumayya Usmani', - 'Mary-Rose Agius', - 'Johan Sorberg', - 'Daisy Garnett', - 'Ken Hom', - 'Phil Howard', - 'Tristan Welch', - 'Oliver Peyton', - 'Hannah Friend', - 'Arthur Potts-Dawson', - 'Dan Lepard and Fiona Beckett', - 'Jane Baxter', - 'Jane Asher', - 'Sophie Missing and Caroline Craig', - 'Uyen Luu', - 'Recipes: Gwyneth Paltrow Introduction: Rebecca Harrington', - 'Yotam Ottolenghi and Alys Fowler', - 'Elisabeth Mahoney', - 'Jane Hornby', - 'Eileen Phillips', - 'Lionel Shriver', - 'Tom Kerridge interviewed by Mina Holland', - 'Kate and Rory Gibson', - 'Marcus Wareing', - 'Matt Tebbutt', - 'Stephen Murray', - 'Jon Dennis', - 'Martin Dewey', - 'Danny Millar', - 'David Tanis', - 'Ursula Ferrigno', - 'Ross Shonhan', - 'Ammo', - 'Interview by Eve O\'Sullivan', - 'Denis Cotter', - 'Jane Clarke', - 'Jane Grigson', - 'Marina O\'Loughlin', - 'Felicity Cloake', - 'Eva Wiseman', - 'Tom Norrington Davies and Trish Hilferty', - 'Nate Booker', - 'Paul A Young', - 'Annie Bell', - 'Niki Kopcke', - 'William Curley', - 'Austin Bush', - 'Darren Ball', - 'Zander Wedderburn', - 'Millicent Bogert', - 'Vincent Graff', - 'Kathleen Alcott', - 'Tim Spector', - 'Dinny Hall', - 'Oliver Hurley', - 'Vefa Alexiadou', - 'Lucinda Bruce-Gardyne', - 'Rick Stein', - 'Javier Laos', - 'Tom Gibson', - 'Jose Pizarro', - 'Ryan Chetiyawardana', - 'Nigel Slater', - 'Nicholas Balfe', - 'Valentina Harris', - 'Francesco Quirico', - 'Anthony Bourdain', - 'Roberto di Matteo', - 'Lindsey Bareham', - 'Dara Mohammadi and Dr Ali Khavandi', - 'Elizabeth Luard', - 'Chris Caldicott', - 'Julia Ponsonby', - 'Amy Cook and Paula Stavrinos', - 'Marcis Dzelzainis', - 'Bob Granleese', - 'Jordan Bourke', - 'James Hall', - 'Pascal Aussignac', - 'Deborah Madison', - 'Atul Kochhar and Fiona Beckett', - 'Amy Raphael', - 'Santiago Guerrero', - 'Dominic Chapman', - 'John Critchley', - 'Claire Lattin and Tom Hill', - 'Bob Granleese and Felicity Cloake', - 'Jekka McVicar', - 'Richard Corrigan', - 'Interview by Sandra Deeble', - 'Mark Bittman', - 'Sam Clark', - 'Interview by Bob Granleese', - 'Itamar Srulovich', - 'Giovanni Spezziga', - 'John Torode', - 'Frances Rivers', - 'Jackson Boxer', - 'Angela Hartnett and Fiona Beckett', - 'Mark Diacono', - 'Tony Conigliaro', - 'Fraser Doherty', - 'Martin Morales', - 'Cyrus Todiwala and Tony Singh', - 'Andrew Cooper', - 'Lindy Wildsmith', - 'Selma Jeevanjee', - 'John Webber at Gidleigh Park', - 'Sophie Conran', - 'Guy Grossi' -]; diff --git a/public/js/util/atomDataExtractors.js b/public/js/util/atomDataExtractors.js index 4d970c2c..e76caba5 100644 --- a/public/js/util/atomDataExtractors.js +++ b/public/js/util/atomDataExtractors.js @@ -11,7 +11,6 @@ export function getTitleForAtom(atom) { switch(atom.atomType) { case ("cta"): return atom.data.cta.label; - case ("recipe"): return atom.data.recipe.title; case ("media"): return atom.data.media.title; case ("qanda"): return atom.title; case ("guide"): return atom.title; From 824040846270695bccaf7f58ab3d972e1a31c098 Mon Sep 17 00:00:00 2001 From: Rowanne Kabalan Date: Thu, 23 Nov 2023 17:08:35 +0000 Subject: [PATCH 2/4] Bump atom-lib and capi-scala-client --- project/Dependencies.scala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/project/Dependencies.scala b/project/Dependencies.scala index 60c1c461..d092c777 100644 --- a/project/Dependencies.scala +++ b/project/Dependencies.scala @@ -3,7 +3,7 @@ import sbt._ object Dependencies { lazy val awsVersion = "1.11.678" - lazy val atomLibVersion = "1.3.2" + lazy val atomLibVersion = "1.4.0" lazy val jacksonVersion = "2.13.4" lazy val jacksonDatabindVersion = "2.13.4.2" @@ -36,6 +36,6 @@ object Dependencies { "io.circe" %% "circe-parser" % "0.11.0", "net.logstash.logback" % "logstash-logback-encoder" % "6.6", "com.gu" %% "content-api-client-aws" % "0.5", - "com.gu" %% "content-api-client" % "15.9" + "com.gu" %% "content-api-client" % "19.5.0" ) } \ No newline at end of file From bf1c99404cddca914d07f13c73488cf271d6b32f Mon Sep 17 00:00:00 2001 From: Rowanne Kabalan Date: Mon, 4 Dec 2023 15:27:10 +0000 Subject: [PATCH 3/4] Bump capi-scala-client --- project/Dependencies.scala | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/project/Dependencies.scala b/project/Dependencies.scala index d092c777..d1302d92 100644 --- a/project/Dependencies.scala +++ b/project/Dependencies.scala @@ -30,12 +30,12 @@ object Dependencies { "com.gu" %% "atom-publisher-lib" % atomLibVersion, "com.gu" %% "editorial-permissions-client" % "2.0", "com.gu" %% "simple-configuration-ssm" % "1.5.6", - "com.gu" %% "fezziwig" % "1.2", + "com.gu" %% "fezziwig" % "1.9", "com.gu" % "kinesis-logback-appender" % "1.4.4", "com.gu" %% "pan-domain-auth-play_2-8" % "1.2.0", - "io.circe" %% "circe-parser" % "0.11.0", + "io.circe" %% "circe-parser" % "0.14.5", "net.logstash.logback" % "logstash-logback-encoder" % "6.6", - "com.gu" %% "content-api-client-aws" % "0.5", - "com.gu" %% "content-api-client" % "19.5.0" + "com.gu" %% "content-api-client-aws" % "0.7", + "com.gu" %% "content-api-client" % "20.0.0" ) } \ No newline at end of file From eb354351df20f034ffd41e1adef2c354764af99a Mon Sep 17 00:00:00 2001 From: Jacob Winch Date: Tue, 5 Dec 2023 12:45:50 +0000 Subject: [PATCH 4/4] Remove DynamoDB template (moving to editorial-tools-platform) --- cloudformation/DynamoTables.yml | 61 --------------------------------- 1 file changed, 61 deletions(-) delete mode 100644 cloudformation/DynamoTables.yml diff --git a/cloudformation/DynamoTables.yml b/cloudformation/DynamoTables.yml deleted file mode 100644 index 1213c1b9..00000000 --- a/cloudformation/DynamoTables.yml +++ /dev/null @@ -1,61 +0,0 @@ -AWSTemplateFormatVersion: '2010-09-09' -Parameters: - Stage: - Type: String - Description: Stage for the tables - AllowedValues: - - DEV - - CODE - - PROD -Resources: - AtomWorkshopPreviewDynamoTable: - Type: AWS::DynamoDB::Table - Properties: - TableName: !Sub atom-workshop-preview-${Stage} - AttributeDefinitions: - - AttributeName: "id" - AttributeType: "S" - - AttributeName: "atomType" - AttributeType: "S" - KeySchema: - - AttributeName: "atomType" - KeyType: "HASH" - - AttributeName: "id" - KeyType: "RANGE" - BillingMode: "PAY_PER_REQUEST" - AtomWorkshopLiveDynamoTable: - Type: AWS::DynamoDB::Table - Properties: - TableName: !Sub atom-workshop-live-${Stage} - AttributeDefinitions: - - AttributeName: "id" - AttributeType: "S" - - AttributeName: "atomType" - AttributeType: "S" - KeySchema: - - AttributeName: "atomType" - KeyType: "HASH" - - AttributeName: "id" - KeyType: "RANGE" - BillingMode: "PAY_PER_REQUEST" -Outputs: - PreviewDynamoTableOut: - Description: Table name for Preview dynamo table - Value: !Ref AtomWorkshopPreviewDynamoTable - Export: - Name: !Sub ${AWS::StackName}-PreviewDynamoTableName - PreviewDynamoArnOut: - Description: ARN for Preview dynamo table - Value: !Sub arn:aws:dynamodb:${AWS::Region}:${AWS::AccountId}:table/${AtomWorkshopPreviewDynamoTable} - Export: - Name: !Sub ${AWS::StackName}-PreviewDynamoTableArn - LiveDynamoTableOut: - Description: Table name for Live dynamo table - Value: !Ref AtomWorkshopLiveDynamoTable - Export: - Name: !Sub ${AWS::StackName}-LiveDynamoTableName - LiveDynamoArnOut: - Description: ARN for Live dynamo table - Value: !Sub arn:aws:dynamodb:${AWS::Region}:${AWS::AccountId}:table/${AtomWorkshopLiveDynamoTable} - Export: - Name: !Sub ${AWS::StackName}-LiveDynamoTableArn