@jsonresume/core 0.1.0

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.
Files changed (279) hide show
  1. package/README.md +689 -0
  2. package/dist/resume-print.css +425 -0
  3. package/dist/tokens.css +139 -0
  4. package/package.json +66 -0
  5. package/src/badges/BadgeRowOutline.jsx +118 -0
  6. package/src/badges/BadgeRowOutline.stories.tsx +160 -0
  7. package/src/badges/index.jsx +5 -0
  8. package/src/callouts/Callout.jsx +80 -0
  9. package/src/callouts/Callout.stories.tsx +27 -0
  10. package/src/callouts/HighlightCard.jsx +114 -0
  11. package/src/callouts/HighlightCard.stories.tsx +27 -0
  12. package/src/callouts/InfoBox.jsx +82 -0
  13. package/src/callouts/InfoBox.stories.tsx +26 -0
  14. package/src/callouts/index.jsx +4 -0
  15. package/src/certifications/AwardCard.jsx +83 -0
  16. package/src/certifications/AwardCard.stories.tsx +32 -0
  17. package/src/certifications/CertificationBadge.jsx +85 -0
  18. package/src/certifications/CertificationBadge.stories.tsx +29 -0
  19. package/src/certifications/CertificationRow.jsx +150 -0
  20. package/src/certifications/CertificationRow.stories.tsx +64 -0
  21. package/src/certifications/HonorsList.jsx +87 -0
  22. package/src/certifications/HonorsList.stories.tsx +36 -0
  23. package/src/certifications/index.jsx +5 -0
  24. package/src/containers/AccentCalloutPanel.jsx +176 -0
  25. package/src/containers/AccentCalloutPanel.stories.tsx +105 -0
  26. package/src/containers/MutedPanel.jsx +125 -0
  27. package/src/containers/MutedPanel.stories.tsx +113 -0
  28. package/src/containers/RoleBlockFramed.jsx +191 -0
  29. package/src/containers/RoleBlockFramed.stories.tsx +230 -0
  30. package/src/containers/SoftCardOutline.jsx +161 -0
  31. package/src/containers/SoftCardOutline.stories.tsx +174 -0
  32. package/src/containers/index.jsx +9 -0
  33. package/src/data/KPIChipLine.jsx +158 -0
  34. package/src/data/KPIChipLine.stories.tsx +99 -0
  35. package/src/data/KeyValueInline.jsx +150 -0
  36. package/src/data/KeyValueInline.stories.tsx +136 -0
  37. package/src/data/MetricBar.jsx +93 -0
  38. package/src/data/MetricBar.stories.tsx +31 -0
  39. package/src/data/MetricBullet.jsx +129 -0
  40. package/src/data/MetricBullet.stories.tsx +99 -0
  41. package/src/data/MetricInline.jsx +60 -0
  42. package/src/data/MetricInline.stories.tsx +53 -0
  43. package/src/data/ProgressCircle.jsx +81 -0
  44. package/src/data/ProgressCircle.stories.tsx +102 -0
  45. package/src/data/StatCard.jsx +65 -0
  46. package/src/data/StatCard.stories.tsx +29 -0
  47. package/src/data/index.jsx +12 -0
  48. package/src/dates/DateBadge.jsx +73 -0
  49. package/src/dates/DateBadge.stories.tsx +30 -0
  50. package/src/dates/RelativeDate.jsx +121 -0
  51. package/src/dates/RelativeDate.stories.tsx +29 -0
  52. package/src/dates/index.jsx +3 -0
  53. package/src/experience/ExperienceCard.jsx +82 -0
  54. package/src/experience/ExperienceCard.stories.tsx +36 -0
  55. package/src/experience/ExperienceCompact.jsx +72 -0
  56. package/src/experience/ExperienceCompact.stories.tsx +53 -0
  57. package/src/experience/ExperienceGrid.jsx +65 -0
  58. package/src/experience/ExperienceGrid.stories.tsx +63 -0
  59. package/src/experience/ExperienceTimeline.jsx +24 -0
  60. package/src/experience/ExperienceTimeline.stories.tsx +63 -0
  61. package/src/experience/RoleHeaderCompact.jsx +99 -0
  62. package/src/experience/index.jsx +9 -0
  63. package/src/header/ContactRowLine.jsx +125 -0
  64. package/src/header/ContactRowLine.stories.tsx +65 -0
  65. package/src/header/CornerInitials.jsx +178 -0
  66. package/src/header/CornerInitials.stories.tsx +129 -0
  67. package/src/header/Footer.jsx +50 -0
  68. package/src/header/Footer.stories.tsx +25 -0
  69. package/src/header/HeaderCentered.jsx +51 -0
  70. package/src/header/HeaderCentered.stories.tsx +30 -0
  71. package/src/header/HeaderMinimal.jsx +50 -0
  72. package/src/header/HeaderMinimal.stories.tsx +29 -0
  73. package/src/header/HeaderSplit.jsx +65 -0
  74. package/src/header/HeaderSplit.stories.tsx +29 -0
  75. package/src/header/HeroNameBlock.jsx +71 -0
  76. package/src/header/HeroNameBlock.stories.tsx +37 -0
  77. package/src/header/NameStackElegant.jsx +104 -0
  78. package/src/header/NameStackElegant.stories.tsx +60 -0
  79. package/src/header/PageBreak.jsx +25 -0
  80. package/src/header/PageBreak.stories.tsx +22 -0
  81. package/src/header/SectionFlagTitle.jsx +87 -0
  82. package/src/header/SectionFlagTitle.stories.tsx +53 -0
  83. package/src/header/SectionRuleTitle.jsx +84 -0
  84. package/src/header/SectionRuleTitle.stories.tsx +52 -0
  85. package/src/header/index.jsx +18 -0
  86. package/src/helpers/calculations.js +428 -0
  87. package/src/index.js +253 -0
  88. package/src/languages/LanguageBar.jsx +90 -0
  89. package/src/languages/LanguageBar.stories.tsx +28 -0
  90. package/src/languages/LanguageGrid.jsx +118 -0
  91. package/src/languages/LanguageGrid.stories.tsx +33 -0
  92. package/src/languages/LanguageLevelBarLite.jsx +147 -0
  93. package/src/languages/LanguageLevelBarLite.stories.tsx +74 -0
  94. package/src/languages/ProficiencyScale.jsx +107 -0
  95. package/src/languages/ProficiencyScale.stories.tsx +30 -0
  96. package/src/languages/index.jsx +5 -0
  97. package/src/layouts/CardLayout.jsx +46 -0
  98. package/src/layouts/CardLayout.stories.tsx +272 -0
  99. package/src/layouts/FlexLayout.jsx +53 -0
  100. package/src/layouts/FlexLayout.stories.tsx +270 -0
  101. package/src/layouts/GridLayout.jsx +38 -0
  102. package/src/layouts/GridLayout.stories.tsx +183 -0
  103. package/src/layouts/SidebarLayout.jsx +63 -0
  104. package/src/layouts/SidebarLayout.stories.tsx +162 -0
  105. package/src/layouts/StackLayout.jsx +26 -0
  106. package/src/layouts/StackLayout.stories.tsx +192 -0
  107. package/src/layouts/TwoColumnMicroGrid.jsx +87 -0
  108. package/src/layouts/TwoColumnMicroGrid.stories.tsx +96 -0
  109. package/src/layouts/index.jsx +11 -0
  110. package/src/lists/AchievementListSpacious.jsx +81 -0
  111. package/src/lists/AchievementListSpacious.stories.tsx +49 -0
  112. package/src/lists/AchievementListTight.jsx +80 -0
  113. package/src/lists/AchievementListTight.stories.tsx +49 -0
  114. package/src/lists/BulletList.jsx +66 -0
  115. package/src/lists/BulletList.stories.tsx +38 -0
  116. package/src/lists/CheckList.jsx +94 -0
  117. package/src/lists/CheckList.stories.tsx +38 -0
  118. package/src/lists/CompactList.jsx +90 -0
  119. package/src/lists/CompactList.stories.tsx +34 -0
  120. package/src/lists/DefinitionKeyline.jsx +114 -0
  121. package/src/lists/DefinitionKeyline.stories.tsx +90 -0
  122. package/src/lists/HangingBulletList.jsx +82 -0
  123. package/src/lists/HangingBulletList.stories.tsx +50 -0
  124. package/src/lists/IconList.jsx +89 -0
  125. package/src/lists/IconList.stories.tsx +36 -0
  126. package/src/lists/ListDashCompact.jsx +69 -0
  127. package/src/lists/ListDashCompact.stories.tsx +60 -0
  128. package/src/lists/MiniDotLeaderList.jsx +69 -0
  129. package/src/lists/MiniDotLeaderList.stories.tsx +73 -0
  130. package/src/lists/NumberedList.jsx +74 -0
  131. package/src/lists/NumberedList.stories.tsx +39 -0
  132. package/src/lists/index.jsx +12 -0
  133. package/src/metadata/GreyLabelCaps.jsx +66 -0
  134. package/src/metadata/GreyLabelCaps.stories.tsx +40 -0
  135. package/src/metadata/InlineKicker.jsx +61 -0
  136. package/src/metadata/InlineKicker.stories.tsx +35 -0
  137. package/src/metadata/MetaRow.jsx +96 -0
  138. package/src/metadata/MetaRow.stories.tsx +38 -0
  139. package/src/metadata/SmallCapsHeading.jsx +75 -0
  140. package/src/metadata/SmallCapsHeading.stories.tsx +54 -0
  141. package/src/metadata/SubsectionLabel.jsx +92 -0
  142. package/src/metadata/SubsectionLabel.stories.tsx +40 -0
  143. package/src/metadata/index.jsx +10 -0
  144. package/src/primitives/AccentSidebarStripe.stories.tsx +65 -0
  145. package/src/primitives/AccentSidebarStripe.tsx +95 -0
  146. package/src/primitives/AccentTopRule.stories.tsx +102 -0
  147. package/src/primitives/AccentTopRule.tsx +103 -0
  148. package/src/primitives/Badge.jsx +125 -0
  149. package/src/primitives/Badge.stories.tsx +27 -0
  150. package/src/primitives/ContactInfo.jsx +133 -0
  151. package/src/primitives/ContactInfo.stories.tsx +30 -0
  152. package/src/primitives/DIVIDERS.md +333 -0
  153. package/src/primitives/DateRange.jsx +178 -0
  154. package/src/primitives/DateRange.stories.tsx +28 -0
  155. package/src/primitives/DottedDivider.stories.tsx +54 -0
  156. package/src/primitives/DottedDivider.tsx +102 -0
  157. package/src/primitives/InlineSeparatorPipe.jsx +64 -0
  158. package/src/primitives/InlineSeparatorPipe.stories.tsx +96 -0
  159. package/src/primitives/KeylineDivider.stories.tsx +48 -0
  160. package/src/primitives/KeylineDivider.tsx +80 -0
  161. package/src/primitives/Link.jsx +59 -0
  162. package/src/primitives/Link.stories.tsx +29 -0
  163. package/src/primitives/ListItem.jsx +127 -0
  164. package/src/primitives/ListItem.stories.tsx +27 -0
  165. package/src/primitives/RulesetStack.stories.tsx +85 -0
  166. package/src/primitives/RulesetStack.tsx +117 -0
  167. package/src/primitives/Section.jsx +37 -0
  168. package/src/primitives/Section.stories.tsx +28 -0
  169. package/src/primitives/SectionTitle.jsx +62 -0
  170. package/src/primitives/SectionTitle.stories.tsx +27 -0
  171. package/src/primitives/index.jsx +36 -0
  172. package/src/print/ColumnBreak.jsx +44 -0
  173. package/src/print/ColumnBreak.stories.tsx +22 -0
  174. package/src/print/KeepTogether.jsx +24 -0
  175. package/src/print/KeepTogether.stories.tsx +26 -0
  176. package/src/print/LetterheadBar.jsx +100 -0
  177. package/src/print/LetterheadBar.stories.tsx +141 -0
  178. package/src/print/PageFooterLine.jsx +93 -0
  179. package/src/print/PageFooterLine.stories.tsx +121 -0
  180. package/src/print/PageHeaderLine.jsx +59 -0
  181. package/src/print/PageHeaderLine.stories.tsx +108 -0
  182. package/src/print/PrintOnly.jsx +49 -0
  183. package/src/print/PrintOnly.stories.tsx +26 -0
  184. package/src/print/SoftShadowEmulation.jsx +88 -0
  185. package/src/print/SoftShadowEmulation.stories.tsx +214 -0
  186. package/src/print/index.jsx +8 -0
  187. package/src/profile/Avatar.jsx +66 -0
  188. package/src/profile/Avatar.stories.tsx +84 -0
  189. package/src/profile/ContactGrid.jsx +63 -0
  190. package/src/profile/ContactGrid.stories.tsx +33 -0
  191. package/src/profile/ProfileCard.jsx +73 -0
  192. package/src/profile/ProfileCard.stories.tsx +35 -0
  193. package/src/profile/SocialLinks.jsx +61 -0
  194. package/src/profile/SocialLinks.stories.tsx +33 -0
  195. package/src/profile/index.jsx +9 -0
  196. package/src/providers/ThemeProvider.jsx +56 -0
  197. package/src/providers/ThemeProvider.stories.tsx +149 -0
  198. package/src/publications/PortfolioGrid.jsx +122 -0
  199. package/src/publications/PortfolioGrid.stories.tsx +62 -0
  200. package/src/publications/ProjectCard.jsx +151 -0
  201. package/src/publications/ProjectCard.stories.tsx +36 -0
  202. package/src/publications/PublicationEntryPlain.jsx +127 -0
  203. package/src/publications/PublicationEntryPlain.stories.tsx +58 -0
  204. package/src/publications/PublicationItem.jsx +120 -0
  205. package/src/publications/PublicationItem.stories.tsx +32 -0
  206. package/src/publications/index.jsx +5 -0
  207. package/src/quotes/BlockQuote.jsx +55 -0
  208. package/src/quotes/BlockQuote.stories.tsx +33 -0
  209. package/src/quotes/PullQuote.jsx +70 -0
  210. package/src/quotes/PullQuote.stories.tsx +32 -0
  211. package/src/quotes/Testimonial.jsx +99 -0
  212. package/src/quotes/Testimonial.stories.tsx +36 -0
  213. package/src/quotes/index.jsx +4 -0
  214. package/src/skills/SkillBar.jsx +66 -0
  215. package/src/skills/SkillBar.stories.tsx +112 -0
  216. package/src/skills/SkillCategory.jsx +71 -0
  217. package/src/skills/SkillCategory.stories.tsx +197 -0
  218. package/src/skills/SkillCloud.jsx +53 -0
  219. package/src/skills/SkillCloud.stories.tsx +132 -0
  220. package/src/skills/SkillGroup.jsx +56 -0
  221. package/src/skills/SkillGroup.stories.tsx +162 -0
  222. package/src/skills/SkillPill.jsx +56 -0
  223. package/src/skills/SkillPill.stories.tsx +157 -0
  224. package/src/skills/SkillRating.jsx +60 -0
  225. package/src/skills/SkillRating.stories.tsx +115 -0
  226. package/src/skills/index.jsx +11 -0
  227. package/src/styles/tokens.css +139 -0
  228. package/src/tables/ComparisonTable.jsx +128 -0
  229. package/src/tables/ComparisonTable.stories.tsx +41 -0
  230. package/src/tables/DataTable.jsx +149 -0
  231. package/src/tables/DataTable.stories.tsx +64 -0
  232. package/src/tables/SkillMatrix.jsx +139 -0
  233. package/src/tables/SkillMatrix.stories.tsx +90 -0
  234. package/src/tables/index.jsx +4 -0
  235. package/src/tags/ToolTagRibbon.jsx +106 -0
  236. package/src/tags/ToolTagRibbon.stories.tsx +121 -0
  237. package/src/tags/index.jsx +5 -0
  238. package/src/timeline/TimelineInline.stories.tsx +83 -0
  239. package/src/timeline/TimelineInline.tsx +202 -0
  240. package/src/timeline/TimelineItem.jsx +106 -0
  241. package/src/timeline/TimelineItem.stories.tsx +64 -0
  242. package/src/timeline/TimelineRuleMinimal.stories.tsx +68 -0
  243. package/src/timeline/TimelineRuleMinimal.tsx +165 -0
  244. package/src/timeline/TimelineSection.jsx +21 -0
  245. package/src/timeline/TimelineSection.stories.tsx +44 -0
  246. package/src/timeline/index.jsx +9 -0
  247. package/src/tokens/index.js +164 -0
  248. package/src/typography/Heading.jsx +48 -0
  249. package/src/typography/Heading.stories.tsx +46 -0
  250. package/src/typography/HyphenationSafeParagraph.jsx +98 -0
  251. package/src/typography/HyphenationSafeParagraph.stories.tsx +151 -0
  252. package/src/typography/Label.jsx +38 -0
  253. package/src/typography/Label.stories.tsx +27 -0
  254. package/src/typography/QuoteStripe.jsx +78 -0
  255. package/src/typography/QuoteStripe.stories.tsx +63 -0
  256. package/src/typography/SectionIntroParagraph.jsx +62 -0
  257. package/src/typography/SectionIntroParagraph.stories.tsx +57 -0
  258. package/src/typography/Text.jsx +42 -0
  259. package/src/typography/Text.stories.tsx +35 -0
  260. package/src/typography/index.jsx +11 -0
  261. package/src/utils/Divider.jsx +32 -0
  262. package/src/utils/Divider.stories.tsx +24 -0
  263. package/src/utils/Flex.jsx +6 -0
  264. package/src/utils/Flex.stories.tsx +28 -0
  265. package/src/utils/Grid.jsx +6 -0
  266. package/src/utils/Grid.stories.tsx +28 -0
  267. package/src/utils/Spacer.jsx +18 -0
  268. package/src/utils/Spacer.stories.tsx +26 -0
  269. package/src/utils/index.jsx +9 -0
  270. package/src/utils/security.js +155 -0
  271. package/src/visuals/BackgroundPattern.jsx +65 -0
  272. package/src/visuals/BackgroundPattern.stories.tsx +27 -0
  273. package/src/visuals/BorderAccent.jsx +147 -0
  274. package/src/visuals/BorderAccent.stories.tsx +27 -0
  275. package/src/visuals/ColorBlock.jsx +60 -0
  276. package/src/visuals/ColorBlock.stories.tsx +27 -0
  277. package/src/visuals/DividerVariants.jsx +120 -0
  278. package/src/visuals/DividerVariants.stories.tsx +27 -0
  279. package/src/visuals/index.jsx +5 -0
@@ -0,0 +1,63 @@
1
+ import React from 'react';
2
+ /**
3
+ * ExperienceTimeline Stories
4
+ */
5
+ import { ExperienceTimeline } from './ExperienceTimeline';
6
+
7
+ const meta = {
8
+ title: 'Resume Core/Experience/ExperienceTimeline',
9
+ component: ExperienceTimeline,
10
+ parameters: { layout: 'padded' },
11
+ tags: ['autodocs'],
12
+ };
13
+
14
+ export default meta;
15
+
16
+ export const Default = {
17
+ args: {
18
+ experiences: [
19
+ {
20
+ position: 'Senior Software Engineer',
21
+ company: 'Tech Corp',
22
+ date: '2020 - Present',
23
+ summary:
24
+ 'Led development of cloud-native microservices architecture serving 1M+ daily active users.',
25
+ },
26
+ {
27
+ position: 'Software Engineer',
28
+ company: 'Innovation Labs',
29
+ date: '2018 - 2020',
30
+ summary:
31
+ 'Built scalable APIs and contributed to open source projects. Improved deployment pipeline reducing release time by 60%.',
32
+ },
33
+ {
34
+ position: 'Junior Developer',
35
+ company: 'WebDev Agency',
36
+ date: '2016 - 2018',
37
+ summary:
38
+ 'Developed responsive websites for clients using React and Node.js. Collaborated with design team on UI/UX improvements.',
39
+ },
40
+ ],
41
+ },
42
+ };
43
+
44
+ export const Example = {
45
+ args: {
46
+ experiences: [
47
+ {
48
+ position: 'Product Manager',
49
+ company: 'StartupXYZ',
50
+ date: 'Jan 2022 - Present',
51
+ summary:
52
+ 'Defined product strategy and roadmap for B2B SaaS platform. Launched 3 major features increasing user engagement by 45%.',
53
+ },
54
+ {
55
+ position: 'Product Owner',
56
+ company: 'Enterprise Corp',
57
+ date: '2019 - 2021',
58
+ summary:
59
+ 'Managed agile development team of 8 engineers. Prioritized backlog and collaborated with stakeholders on feature requirements.',
60
+ },
61
+ ],
62
+ },
63
+ };
@@ -0,0 +1,99 @@
1
+ import React from 'react';
2
+ import styled from 'styled-components';
3
+
4
+ /**
5
+ * RoleHeaderCompact
6
+ *
7
+ * Tight role header stack with locked line-heights for consistency.
8
+ * Stacks Title (bold) / Company (regular) / Dates+Location (muted).
9
+ * Optimized for print with consistent spacing.
10
+ *
11
+ * @param {Object} props - Component props
12
+ * @param {string} props.title - Job title
13
+ * @param {string} props.company - Company name
14
+ * @param {string} [props.location] - Location (optional)
15
+ * @param {string} [props.date] - Date range (optional)
16
+ * @param {string} [props.className] - Additional CSS classes
17
+ *
18
+ * @example
19
+ * ```jsx
20
+ * <RoleHeaderCompact
21
+ * title="Senior Software Engineer"
22
+ * company="Acme Corp"
23
+ * location="San Francisco, CA"
24
+ * date="Jan 2020 - Present"
25
+ * />
26
+ * ```
27
+ */
28
+
29
+ const Container = styled.div`
30
+ display: flex;
31
+ flex-direction: column;
32
+ gap: 2px;
33
+ margin-bottom: var(--resume-space-tight);
34
+
35
+ @media print {
36
+ break-inside: avoid;
37
+ page-break-inside: avoid;
38
+ }
39
+ `;
40
+
41
+ const Title = styled.div`
42
+ font-size: var(--resume-size-subheading);
43
+ font-weight: var(--resume-weight-bold);
44
+ color: var(--resume-color-primary);
45
+ line-height: 1.2;
46
+ margin: 0;
47
+
48
+ @media print {
49
+ line-height: 1.2;
50
+ }
51
+ `;
52
+
53
+ const Company = styled.div`
54
+ font-size: var(--resume-size-body);
55
+ font-weight: var(--resume-weight-normal);
56
+ color: var(--resume-color-primary);
57
+ line-height: 1.3;
58
+ margin: 0;
59
+
60
+ @media print {
61
+ line-height: 1.3;
62
+ }
63
+ `;
64
+
65
+ const Meta = styled.div`
66
+ font-size: var(--resume-size-small);
67
+ font-weight: var(--resume-weight-normal);
68
+ color: var(--resume-color-secondary);
69
+ line-height: 1.3;
70
+ margin: 0;
71
+
72
+ @media print {
73
+ line-height: 1.3;
74
+ }
75
+ `;
76
+
77
+ export function RoleHeaderCompact({
78
+ title,
79
+ company,
80
+ location,
81
+ date,
82
+ className,
83
+ }) {
84
+ return (
85
+ <Container className={className}>
86
+ {title && <Title>{title}</Title>}
87
+ {company && <Company>{company}</Company>}
88
+ {(location || date) && (
89
+ <Meta>
90
+ {location && <span>{location}</span>}
91
+ {location && date && <span> • </span>}
92
+ {date && <span>{date}</span>}
93
+ </Meta>
94
+ )}
95
+ </Container>
96
+ );
97
+ }
98
+
99
+ export default RoleHeaderCompact;
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ /**
3
+ * Experience Components
4
+ * Export all experience display components
5
+ */
6
+ export { ExperienceCard } from './ExperienceCard.jsx';
7
+ export { ExperienceTimeline } from './ExperienceTimeline.jsx';
8
+ export { ExperienceGrid } from './ExperienceGrid.jsx';
9
+ export { ExperienceCompact } from './ExperienceCompact.jsx';
@@ -0,0 +1,125 @@
1
+ import React from 'react';
2
+ import styled from 'styled-components';
3
+
4
+ /**
5
+ * ContactRowLine Component
6
+ * Single-line contact information strip with middle dots as separators
7
+ *
8
+ * @component
9
+ * @example
10
+ * <ContactRowLine items={[
11
+ * { text: "jane@example.com", href: "mailto:jane@example.com" },
12
+ * { text: "(555) 123-4567" },
13
+ * { text: "San Francisco, CA" }
14
+ * ]} />
15
+ *
16
+ * @param {Object} props
17
+ * @param {Array<{text: string, href?: string}>} props.items - Contact items to display
18
+ * @param {string} [props.separator='·'] - Separator character between items
19
+ * @param {string} [props.className] - Additional CSS classes
20
+ */
21
+
22
+ const Container = styled.div`
23
+ display: flex;
24
+ align-items: center;
25
+ justify-content: center;
26
+ gap: 12px;
27
+ font-size: var(--resume-size-body, 11px);
28
+ color: var(--resume-color-secondary, #4a4a4a);
29
+ line-height: 1.4;
30
+ white-space: nowrap;
31
+ overflow: hidden;
32
+ text-overflow: ellipsis;
33
+
34
+ /* Prevent wrapping to maintain single-line layout */
35
+ flex-wrap: nowrap;
36
+
37
+ @media print {
38
+ color: #333333; /* Ensure 4.5:1 contrast for print */
39
+ }
40
+
41
+ /* Handle overflow gracefully on very narrow screens */
42
+ @media (max-width: 480px) {
43
+ font-size: 10px;
44
+ gap: 8px;
45
+ }
46
+ `;
47
+
48
+ const ContactItem = styled.span`
49
+ display: inline-flex;
50
+ align-items: center;
51
+ white-space: nowrap;
52
+ `;
53
+
54
+ const ContactLink = styled.a`
55
+ color: inherit;
56
+ text-decoration: none;
57
+
58
+ &:hover {
59
+ color: var(--resume-color-accent, #2563eb);
60
+ text-decoration: underline;
61
+ }
62
+
63
+ @media print {
64
+ color: #333333;
65
+ text-decoration: none;
66
+ }
67
+ `;
68
+
69
+ const Separator = styled.span`
70
+ color: var(--resume-color-border, #e5e7eb);
71
+ user-select: none;
72
+ font-weight: var(--resume-weight-normal, 400);
73
+
74
+ @media print {
75
+ color: #999999;
76
+ }
77
+ `;
78
+
79
+ export function ContactRowLine({
80
+ items = [],
81
+ separator = '·',
82
+ className,
83
+ ...rest
84
+ }) {
85
+ if (!items || items.length === 0) {
86
+ return null;
87
+ }
88
+
89
+ return (
90
+ <Container
91
+ className={`resume-contact-row ${className || ''}`.trim()}
92
+ {...rest}
93
+ >
94
+ {items.map((item, index) => (
95
+ <React.Fragment key={index}>
96
+ <ContactItem className="resume-contact-item">
97
+ {item.href ? (
98
+ <ContactLink
99
+ href={item.href}
100
+ className="resume-contact-link"
101
+ target={item.href.startsWith('http') ? '_blank' : undefined}
102
+ rel={
103
+ item.href.startsWith('http')
104
+ ? 'noopener noreferrer'
105
+ : undefined
106
+ }
107
+ >
108
+ {item.text}
109
+ </ContactLink>
110
+ ) : (
111
+ item.text
112
+ )}
113
+ </ContactItem>
114
+ {index < items.length - 1 && (
115
+ <Separator aria-hidden="true" className="resume-contact-separator">
116
+ {separator}
117
+ </Separator>
118
+ )}
119
+ </React.Fragment>
120
+ ))}
121
+ </Container>
122
+ );
123
+ }
124
+
125
+ export default ContactRowLine;
@@ -0,0 +1,65 @@
1
+ import React from 'react';
2
+ import { ContactRowLine } from './ContactRowLine';
3
+
4
+ const meta = {
5
+ title: 'Resume Core/Header/ContactRowLine',
6
+ component: ContactRowLine,
7
+ parameters: { layout: 'padded' },
8
+ tags: ['autodocs'],
9
+ };
10
+
11
+ export default meta;
12
+
13
+ export const Default = {
14
+ args: {
15
+ items: [
16
+ { text: 'jane.smith@example.com', href: 'mailto:jane.smith@example.com' },
17
+ { text: '(555) 123-4567', href: 'tel:+15551234567' },
18
+ { text: 'San Francisco, CA' },
19
+ ],
20
+ },
21
+ };
22
+
23
+ export const WithLinks = {
24
+ args: {
25
+ items: [
26
+ { text: 'john.doe@example.com', href: 'mailto:john.doe@example.com' },
27
+ {
28
+ text: 'linkedin.com/in/johndoe',
29
+ href: 'https://linkedin.com/in/johndoe',
30
+ },
31
+ { text: 'github.com/johndoe', href: 'https://github.com/johndoe' },
32
+ ],
33
+ },
34
+ };
35
+
36
+ export const Minimal = {
37
+ args: {
38
+ items: [
39
+ { text: 'alex@example.com', href: 'mailto:alex@example.com' },
40
+ { text: 'New York, NY' },
41
+ ],
42
+ },
43
+ };
44
+
45
+ export const CustomSeparator = {
46
+ args: {
47
+ items: [
48
+ { text: 'contact@example.com' },
49
+ { text: '(555) 987-6543' },
50
+ { text: 'Boston, MA' },
51
+ ],
52
+ separator: '|',
53
+ },
54
+ };
55
+
56
+ export const SingleItem = {
57
+ args: {
58
+ items: [
59
+ {
60
+ text: 'singlecontact@example.com',
61
+ href: 'mailto:singlecontact@example.com',
62
+ },
63
+ ],
64
+ },
65
+ };
@@ -0,0 +1,178 @@
1
+ import React from 'react';
2
+ /**
3
+ * CornerInitials
4
+ * Small monogram initials component for corner placement
5
+ * Optimized for letterhead-style resume headers
6
+ */
7
+ import styled from 'styled-components';
8
+
9
+ const Container = styled.div`
10
+ position: ${(props) =>
11
+ props.$position === 'absolute' ? 'absolute' : 'relative'};
12
+ ${(props) => props.$corner === 'top-left' && 'top: 0; left: 0;'}
13
+ ${(props) => props.$corner === 'top-right' && 'top: 0; right: 0;'}
14
+ ${(props) => props.$corner === 'bottom-left' && 'bottom: 0; left: 0;'}
15
+ ${(props) => props.$corner === 'bottom-right' && 'bottom: 0; right: 0;'}
16
+ display: inline-flex;
17
+ align-items: center;
18
+ justify-content: center;
19
+ width: ${(props) => props.$size || '48px'};
20
+ height: ${(props) => props.$size || '48px'};
21
+
22
+ @media print {
23
+ break-inside: avoid;
24
+ page-break-inside: avoid;
25
+ }
26
+ `;
27
+
28
+ const Initials = styled.div`
29
+ font-family: ${(props) =>
30
+ props.$serif ? 'Georgia, "Times New Roman", serif' : 'inherit'};
31
+ font-size: ${(props) =>
32
+ props.$fontSize || 'calc(var(--resume-size-heading) * 0.8)'};
33
+ font-weight: ${(props) =>
34
+ props.$outline
35
+ ? 'var(--resume-weight-normal)'
36
+ : 'var(--resume-weight-bold)'};
37
+ color: ${(props) => props.$color || 'var(--resume-color-primary)'};
38
+ line-height: 1;
39
+ text-transform: uppercase;
40
+ letter-spacing: ${(props) => (props.$outline ? '1px' : '0')};
41
+
42
+ ${(props) =>
43
+ props.$outline &&
44
+ `
45
+ -webkit-text-stroke: 1px ${props.$color || 'var(--resume-color-primary)'};
46
+ -webkit-text-fill-color: transparent;
47
+ text-stroke: 1px ${props.$color || 'var(--resume-color-primary)'};
48
+ text-fill-color: transparent;
49
+ `}
50
+
51
+ ${(props) =>
52
+ props.$bordered &&
53
+ `
54
+ border: 2px solid ${props.$color || 'var(--resume-color-primary)'};
55
+ border-radius: ${props.$rounded ? '50%' : 'var(--resume-radius-sm)'};
56
+ padding: ${props.$padding || '8px'};
57
+ width: ${props.$size || '48px'};
58
+ height: ${props.$size || '48px'};
59
+ display: flex;
60
+ align-items: center;
61
+ justify-content: center;
62
+ `}
63
+
64
+ @media print {
65
+ ${(props) =>
66
+ props.$outline &&
67
+ `
68
+ color: ${props.$color || 'var(--resume-color-primary)'};
69
+ -webkit-text-stroke: none;
70
+ -webkit-text-fill-color: ${props.$color || 'var(--resume-color-primary)'};
71
+ font-weight: var(--resume-weight-normal);
72
+ `}
73
+ }
74
+ `;
75
+
76
+ /**
77
+ * Extract initials from name
78
+ * @param {string} name - Full name
79
+ * @returns {string} Initials (max 3 characters)
80
+ */
81
+ function extractInitials(name) {
82
+ if (!name) return '';
83
+
84
+ const parts = name.trim().split(/\s+/);
85
+
86
+ if (parts.length === 1) {
87
+ // Single name: take first 2 letters
88
+ return parts[0].substring(0, 2).toUpperCase();
89
+ } else if (parts.length === 2) {
90
+ // Two names: first letter of each
91
+ return (parts[0][0] + parts[1][0]).toUpperCase();
92
+ } else {
93
+ // Three or more: first, middle, last
94
+ return (
95
+ parts[0][0] +
96
+ parts[1][0] +
97
+ parts[parts.length - 1][0]
98
+ ).toUpperCase();
99
+ }
100
+ }
101
+
102
+ /**
103
+ * CornerInitials Component
104
+ *
105
+ * Displays monogram initials for decorative corner placement in resume headers.
106
+ * Supports outline style for thin fonts and bordered variants for emphasis.
107
+ *
108
+ * @param {Object} props - Component props
109
+ * @param {string} props.name - Full name to extract initials from
110
+ * @param {string} [props.initials] - Custom initials (overrides name extraction)
111
+ * @param {string} [props.corner='top-left'] - Corner position (top-left, top-right, bottom-left, bottom-right)
112
+ * @param {string} [props.position='absolute'] - CSS position (absolute, relative)
113
+ * @param {string} [props.size='48px'] - Container size
114
+ * @param {string} [props.fontSize] - Font size (defaults to calculated value)
115
+ * @param {string} [props.color] - Text/border color
116
+ * @param {boolean} [props.outline=false] - Use outline style (recommended for thin fonts)
117
+ * @param {boolean} [props.bordered=false] - Add border around initials
118
+ * @param {boolean} [props.rounded=false] - Make border circular (requires bordered=true)
119
+ * @param {boolean} [props.serif=false] - Use serif font family
120
+ * @param {string} [props.padding='8px'] - Internal padding (for bordered variant)
121
+ * @param {string} [props.className] - Additional CSS classes
122
+ *
123
+ * @example
124
+ * ```jsx
125
+ * // Simple corner initials
126
+ * <CornerInitials name="John Smith" corner="top-right" />
127
+ *
128
+ * // Outline style for thin fonts
129
+ * <CornerInitials name="Jane Doe" outline serif />
130
+ *
131
+ * // Bordered circular monogram
132
+ * <CornerInitials name="Alex Johnson" bordered rounded size="64px" />
133
+ *
134
+ * // Custom initials
135
+ * <CornerInitials initials="JQ" color="#0066cc" />
136
+ * ```
137
+ */
138
+ export function CornerInitials({
139
+ name,
140
+ initials,
141
+ corner = 'top-left',
142
+ position = 'absolute',
143
+ size = '48px',
144
+ fontSize,
145
+ color,
146
+ outline = false,
147
+ bordered = false,
148
+ rounded = false,
149
+ serif = false,
150
+ padding = '8px',
151
+ className,
152
+ }) {
153
+ const displayInitials = initials || extractInitials(name);
154
+
155
+ return (
156
+ <Container
157
+ $corner={corner}
158
+ $position={position}
159
+ $size={size}
160
+ className={className}
161
+ >
162
+ <Initials
163
+ $fontSize={fontSize}
164
+ $color={color}
165
+ $outline={outline}
166
+ $bordered={bordered}
167
+ $rounded={rounded}
168
+ $serif={serif}
169
+ $size={size}
170
+ $padding={padding}
171
+ >
172
+ {displayInitials}
173
+ </Initials>
174
+ </Container>
175
+ );
176
+ }
177
+
178
+ export default CornerInitials;
@@ -0,0 +1,129 @@
1
+ import type { Meta, StoryObj } from '@storybook/react';
2
+ import { CornerInitials } from './CornerInitials';
3
+
4
+ const meta = {
5
+ title: 'Header/CornerInitials',
6
+ component: CornerInitials,
7
+ tags: ['autodocs'],
8
+ } satisfies Meta<typeof CornerInitials>;
9
+
10
+ export default meta;
11
+ type Story = StoryObj<typeof meta>;
12
+
13
+ export const Default: Story = {
14
+ args: {
15
+ name: 'John Smith',
16
+ position: 'relative',
17
+ },
18
+ };
19
+
20
+ export const CustomInitials: Story = {
21
+ args: {
22
+ initials: 'JQ',
23
+ position: 'relative',
24
+ },
25
+ };
26
+
27
+ export const Outline: Story = {
28
+ args: {
29
+ name: 'Jane Doe',
30
+ outline: true,
31
+ position: 'relative',
32
+ },
33
+ };
34
+
35
+ export const OutlineSerif: Story = {
36
+ args: {
37
+ name: 'Alex Johnson',
38
+ outline: true,
39
+ serif: true,
40
+ position: 'relative',
41
+ },
42
+ };
43
+
44
+ export const Bordered: Story = {
45
+ args: {
46
+ name: 'Maria Garcia',
47
+ bordered: true,
48
+ position: 'relative',
49
+ },
50
+ };
51
+
52
+ export const BorderedRounded: Story = {
53
+ args: {
54
+ name: 'Robert Chen',
55
+ bordered: true,
56
+ rounded: true,
57
+ position: 'relative',
58
+ },
59
+ };
60
+
61
+ export const LargeSize: Story = {
62
+ args: {
63
+ name: 'Sarah Williams',
64
+ size: '80px',
65
+ bordered: true,
66
+ rounded: true,
67
+ position: 'relative',
68
+ },
69
+ };
70
+
71
+ export const CustomColor: Story = {
72
+ args: {
73
+ name: 'David Brown',
74
+ color: '#0066cc',
75
+ bordered: true,
76
+ position: 'relative',
77
+ },
78
+ };
79
+
80
+ export const ThreeInitials: Story = {
81
+ args: {
82
+ name: 'John Patrick Smith',
83
+ bordered: true,
84
+ rounded: true,
85
+ position: 'relative',
86
+ },
87
+ };
88
+
89
+ export const InCorner: Story = {
90
+ render: () => (
91
+ <div
92
+ style={{
93
+ position: 'relative',
94
+ width: '600px',
95
+ height: '300px',
96
+ border: '2px solid #ddd',
97
+ padding: '20px',
98
+ }}
99
+ >
100
+ <CornerInitials name="Jessica Taylor" corner="top-right" />
101
+ <h1 style={{ marginTop: '60px' }}>Resume Content</h1>
102
+ <p>
103
+ The initials appear in the top-right corner when position is absolute.
104
+ </p>
105
+ </div>
106
+ ),
107
+ };
108
+
109
+ export const AllCorners: Story = {
110
+ render: () => (
111
+ <div
112
+ style={{
113
+ position: 'relative',
114
+ width: '600px',
115
+ height: '400px',
116
+ border: '2px solid #ddd',
117
+ }}
118
+ >
119
+ <CornerInitials name="Top Left" corner="top-left" size="40px" />
120
+ <CornerInitials name="Top Right" corner="top-right" size="40px" />
121
+ <CornerInitials name="Bottom Left" corner="bottom-left" size="40px" />
122
+ <CornerInitials name="Bottom Right" corner="bottom-right" size="40px" />
123
+ <div style={{ padding: '60px 20px', textAlign: 'center' }}>
124
+ <h2>Resume Header</h2>
125
+ <p>Content area with initials in all four corners</p>
126
+ </div>
127
+ </div>
128
+ ),
129
+ };