Import the remade decks on stable ids and recommend one card per job, so a saved draft still loads after a chip is renamed.
The real-group profiles stay as a test, so a change that moves a pick fails. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
96ca15d8e3
commit
bcbc6f30d9
89 files changed
+36555
-2828
No files matched your search
@@ -0,0 +1,31 @@
|
||||
import type { CommunityRuleSection } from "../../app/components/type/CommunityRule/CommunityRule.types";
|
||||
import sharedTerms from "../../messages/en/create/sharedTerms.json";
|
||||
|
||||
/** Fixed at launch. Cards that omit a consensus level read this share. */
|
||||
export const LAUNCH_SUPERMAJORITY_SHARE = 75;
|
||||
|
||||
type SharedTerm = { term: string; meaning: string };
|
||||
|
||||
/**
|
||||
* Every shared term, definitions only. Fallbacks for a skipped topic do not print.
|
||||
* Use-case example Rules do not call this.
|
||||
*/
|
||||
export function sharedTermsSection(): CommunityRuleSection {
|
||||
const terms = (sharedTerms as { terms: SharedTerm[] }).terms;
|
||||
return {
|
||||
categoryName: sharedTerms.sectionTitle,
|
||||
entries: terms.map((term) => ({
|
||||
title: term.term,
|
||||
body: term.meaning,
|
||||
})),
|
||||
};
|
||||
}
|
||||
|
||||
export function withSharedTerms(
|
||||
sections: CommunityRuleSection[],
|
||||
): CommunityRuleSection[] {
|
||||
if (sections.some((section) => section.categoryName === sharedTerms.sectionTitle)) {
|
||||
return sections;
|
||||
}
|
||||
return [...sections, sharedTermsSection()];
|
||||
}
|
||||
Reference in new issue
Block a user