@guardian/atoms-rendering
Advanced tools
Comparing version 25.1.0 to 25.1.1
# @guardian/atoms-rendering | ||
## 25.1.1 | ||
### Patch Changes | ||
- 0e19d91: Adding data-ignore attribute to KnowledgeQuiz atom ordered lists to remove duplicate list numbers | ||
## 25.1.0 | ||
@@ -4,0 +10,0 @@ |
@@ -22,3 +22,3 @@ 'use strict'; | ||
const haveAllQuestionsBeenAnswered = Object.keys(quizSelection).length === questions.length; | ||
return (jsxRuntime.jsxs("form", { "data-atom-id": id, "data-atom-type": "knowledgequiz", children: [haveAllQuestionsBeenAnswered && (jsxRuntime.jsx("div", { "data-testid": "quiz-results-block-top", children: jsxRuntime.jsx(Result, { quizSelection: quizSelection, resultGroups: resultGroups, sharingUrls: sharingUrls }) })), jsxRuntime.jsx("ol", { children: questions.map((question, idx) => (jsxRuntime.jsx(Question, { id: question.id, number: idx + 1, text: question.text, imageUrl: question.imageUrl, imageAlt: question.imageAlt, answers: question.answers, quizSelection: quizSelection, setQuizSelection: setQuizSelection, theme: theme }, question.id))) }), haveAllQuestionsBeenAnswered && (jsxRuntime.jsx("div", { "data-testid": "quiz-results-block-top", children: jsxRuntime.jsx(Result, { quizSelection: quizSelection, resultGroups: resultGroups, sharingUrls: sharingUrls }) }))] })); | ||
return (jsxRuntime.jsxs("form", { "data-atom-id": id, "data-atom-type": "knowledgequiz", children: [haveAllQuestionsBeenAnswered && (jsxRuntime.jsx("div", { "data-testid": "quiz-results-block-top", children: jsxRuntime.jsx(Result, { quizSelection: quizSelection, resultGroups: resultGroups, sharingUrls: sharingUrls }) })), jsxRuntime.jsx("ol", { "data-ignore": "global-ol-styling", children: questions.map((question, idx) => (jsxRuntime.jsx(Question, { id: question.id, number: idx + 1, text: question.text, imageUrl: question.imageUrl, imageAlt: question.imageAlt, answers: question.answers, quizSelection: quizSelection, setQuizSelection: setQuizSelection, theme: theme }, question.id))) }), haveAllQuestionsBeenAnswered && (jsxRuntime.jsx("div", { "data-testid": "quiz-results-block-top", children: jsxRuntime.jsx(Result, { quizSelection: quizSelection, resultGroups: resultGroups, sharingUrls: sharingUrls }) }))] })); | ||
}; | ||
@@ -25,0 +25,0 @@ const Question = ({ id, text, imageUrl, imageAlt, answers, number, quizSelection, setQuizSelection, theme, }) => { |
@@ -18,3 +18,3 @@ import { jsxs, jsx } from '@emotion/react/jsx-runtime'; | ||
const haveAllQuestionsBeenAnswered = Object.keys(quizSelection).length === questions.length; | ||
return (jsxs("form", { "data-atom-id": id, "data-atom-type": "knowledgequiz", children: [haveAllQuestionsBeenAnswered && (jsx("div", { "data-testid": "quiz-results-block-top", children: jsx(Result, { quizSelection: quizSelection, resultGroups: resultGroups, sharingUrls: sharingUrls }) })), jsx("ol", { children: questions.map((question, idx) => (jsx(Question, { id: question.id, number: idx + 1, text: question.text, imageUrl: question.imageUrl, imageAlt: question.imageAlt, answers: question.answers, quizSelection: quizSelection, setQuizSelection: setQuizSelection, theme: theme }, question.id))) }), haveAllQuestionsBeenAnswered && (jsx("div", { "data-testid": "quiz-results-block-top", children: jsx(Result, { quizSelection: quizSelection, resultGroups: resultGroups, sharingUrls: sharingUrls }) }))] })); | ||
return (jsxs("form", { "data-atom-id": id, "data-atom-type": "knowledgequiz", children: [haveAllQuestionsBeenAnswered && (jsx("div", { "data-testid": "quiz-results-block-top", children: jsx(Result, { quizSelection: quizSelection, resultGroups: resultGroups, sharingUrls: sharingUrls }) })), jsx("ol", { "data-ignore": "global-ol-styling", children: questions.map((question, idx) => (jsx(Question, { id: question.id, number: idx + 1, text: question.text, imageUrl: question.imageUrl, imageAlt: question.imageAlt, answers: question.answers, quizSelection: quizSelection, setQuizSelection: setQuizSelection, theme: theme }, question.id))) }), haveAllQuestionsBeenAnswered && (jsx("div", { "data-testid": "quiz-results-block-top", children: jsx(Result, { quizSelection: quizSelection, resultGroups: resultGroups, sharingUrls: sharingUrls }) }))] })); | ||
}; | ||
@@ -21,0 +21,0 @@ const Question = ({ id, text, imageUrl, imageAlt, answers, number, quizSelection, setQuizSelection, theme, }) => { |
{ | ||
"name": "@guardian/atoms-rendering", | ||
"version": "25.1.0", | ||
"version": "25.1.1", | ||
"homepage": "https://github.com/guardian/csnx/tree/main/libs/@guardian/atoms-rendering#readme", | ||
@@ -42,3 +42,3 @@ "bugs": { | ||
"readme": "ERROR: No README data found!", | ||
"_id": "@guardian/atoms-rendering@25.1.0" | ||
"_id": "@guardian/atoms-rendering@25.1.1" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
664048
6081