@team-monolith/cds 1.117.20 → 1.117.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -13,6 +13,7 @@ import { SettingForm } from "./SettingForm";
13
13
  import styled from "@emotion/styled";
14
14
  import { LexicalCustomConfigContext } from "../../LexicalCustomConfigContext";
15
15
  import { useTranslation } from "react-i18next";
16
+ import { getTexts } from "../../../../texts";
16
17
  export function SelectComponent(props) {
17
18
  const { selected, hasMultipleSolutions, selections, nodeKey } = props;
18
19
  const [editor] = useLexicalComposerContext();
@@ -35,7 +36,7 @@ export function SelectComponent(props) {
35
36
  `, children: [multipleSelectionsEnabled && (_jsxs(Alert, { children: [_jsx(AlarmWarningFillIcon, { css: css `
36
37
  width: 14px;
37
38
  height: 14px;
38
- ` }), t("질문에 해당하는 답을 모두 고르는 문제입니다.")] })), selections.map((selection, index) => (_jsx(SelectBoxView, { multipleSelectionsEnabled: multipleSelectionsEnabled, index: index + 1, isAnswer: showQuizSolution && "isAnswer" in selection
39
+ ` }), getTexts("multipleChoicesProblem")] })), selections.map((selection, index) => (_jsx(SelectBoxView, { multipleSelectionsEnabled: multipleSelectionsEnabled, index: index + 1, isAnswer: showQuizSolution && "isAnswer" in selection
39
40
  ? selection.isAnswer
40
41
  : undefined, isSelected: selected.includes(selection.value), image: selection.show.image, text: selection.show.text, onClick: freezeProblemNode
41
42
  ? undefined
@@ -13,6 +13,7 @@ import { SquareButton } from "../../../../../components/SquareButton";
13
13
  import { SettingForm } from "./SettingForm";
14
14
  import { SelectBoxEdit, SelectBoxView } from "./SelectBox";
15
15
  import { useTranslation } from "react-i18next";
16
+ import { getTexts } from "../../../../../texts";
16
17
  export function SelectComponent(props) {
17
18
  const { selections, selected, allowMultipleAnswers, nodeKey } = props;
18
19
  const [editor] = useLexicalComposerContext();
@@ -25,7 +26,7 @@ export function SelectComponent(props) {
25
26
  return (_jsxs(_Fragment, { children: [allowMultipleAnswers && (_jsxs(Alert, { children: [_jsx(AlarmWarningFillIcon, { css: css `
26
27
  width: 14px;
27
28
  height: 14px;
28
- ` }), t("질문에 해당하는 답을 모두 고르는 문제입니다.")] })), selections.map((selection, index) => (_jsx(SelectBoxView, { index: index + 1, isSelected: selected.includes(selection.value), image: selection.show.image, text: selection.show.text, onClick: freezeProblemNode
29
+ ` }), getTexts("multipleChoicesProblem")] })), selections.map((selection, index) => (_jsx(SelectBoxView, { index: index + 1, isSelected: selected.includes(selection.value), image: selection.show.image, text: selection.show.text, onClick: freezeProblemNode
29
30
  ? undefined
30
31
  : () => {
31
32
  const isSelected = selected.includes(selection.value);
package/dist/texts.d.ts CHANGED
@@ -7,6 +7,7 @@ type TranslationMap = {
7
7
  errorRequiredField: string;
8
8
  errorDuplicateChoice: (indexes: string) => string;
9
9
  errorMaxChoicesExceeded: string;
10
+ multipleChoicesProblem: string;
10
11
  };
11
12
  export declare function getTexts<K extends keyof TranslationMap>(key: K): TranslationMap[K];
12
13
  export {};
package/dist/texts.js CHANGED
@@ -8,6 +8,7 @@ const TRANSLATION_TEXT = {
8
8
  errorRequiredField: () => i18n.t("필수 입력 항목입니다."),
9
9
  errorDuplicateChoice: () => (indexes) => i18n.t("{{indexes}}번 선택지가 같은 내용입니다.", { indexes }),
10
10
  errorMaxChoicesExceeded: () => i18n.t("선택지는 9개까지 등록이 가능합니다."),
11
+ multipleChoicesProblem: () => i18n.t("질문에 해당하는 답을 모두 고르는 문제입니다."),
11
12
  };
12
13
  export function getTexts(key) {
13
14
  return TRANSLATION_TEXT[key]();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@team-monolith/cds",
3
- "version": "1.117.20",
3
+ "version": "1.117.21",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "sideEffects": false,