diff --git a/HappyAnding/HappyAnding/Extensions/View/View+Font.swift b/HappyAnding/HappyAnding/Extensions/View/View+Font.swift index 8c6da923..cb6aa041 100644 --- a/HappyAnding/HappyAnding/Extensions/View/View+Font.swift +++ b/HappyAnding/HappyAnding/Extensions/View/View+Font.swift @@ -18,6 +18,13 @@ enum Pretendard: String { case bold = "Pretendard-Bold" } +enum SFCompactRounded: String { + case regular = "SF-Compact-Rounded-Regular" + case medium = "SF-Compact-Rounded-Medium" + case semiBold = "SF-Compact-Rounded-Semibold" + case bold = "SF-Compact-Rounded-Bold" +} + ///Pretendard 폰트를 기존 modifier와 같이 사용할 수 있게 해 주는 Extension ///사용 예시 ///Text("단축어").largeTitle() @@ -55,6 +62,10 @@ extension View { func customPretendard(fontName: Pretendard, size: CGFloat) -> some View { self.modifier(CustomFontStyle(fontName: fontName.rawValue, size: size)) } + + func customSFCompactRounded(fontName: SFCompactRounded, size: CGFloat) -> some View { + self.modifier(CustomFontStyle(fontName: fontName.rawValue, size: size)) + } } struct CustomFontStyle: ViewModifier { diff --git a/HappyAnding/HappyAnding/Extensions/View/View+UIFont.swift b/HappyAnding/HappyAnding/Extensions/View/View+UIFont.swift index 546ecb8d..476014e0 100644 --- a/HappyAnding/HappyAnding/Extensions/View/View+UIFont.swift +++ b/HappyAnding/HappyAnding/Extensions/View/View+UIFont.swift @@ -64,9 +64,27 @@ extension View { func smallShortcutIcon() -> some View { ModifiedContent(content: self, modifier: FontWithLineHeight(font: .smallShortcutIcon, lineHeight: 20)) } + func regular16() -> some View { + ModifiedContent(content: self, modifier: FontWithLineHeight(font: UIFont(name: Pretendard.regular.rawValue, size: 16) ?? UIFont.systemFont(ofSize: 16), lineHeight: 24)) + } + func medium16() -> some View { + ModifiedContent(content: self, modifier: FontWithLineHeight(font: UIFont(name: Pretendard.medium.rawValue, size: 16) ?? UIFont.systemFont(ofSize: 16), lineHeight: 24)) + } + func medium17() -> some View { + ModifiedContent(content: self, modifier: FontWithLineHeight(font: UIFont(name: Pretendard.medium.rawValue, size: 17) ?? UIFont.systemFont(ofSize: 17), lineHeight: 24)) + } + func semiBold17() -> some View { + ModifiedContent(content: self, modifier: FontWithLineHeight(font: UIFont(name: Pretendard.semiBold.rawValue, size: 17) ?? UIFont.systemFont(ofSize: 17), lineHeight: 24)) + } + func numRegular16() -> some View { + ModifiedContent(content: self, modifier: FontWithLineHeight(font: UIFont(name: SFCompactRounded.regular.rawValue, size: 16) ?? UIFont.systemFont(ofSize: 16), lineHeight: 24)) + } + + func descriptionReadable() -> some View { + ModifiedContent(content: self, modifier: FontWithLineHeight(font: UIFont(name: Pretendard.regular.rawValue, size: 16) ?? UIFont.systemFont(ofSize: 16), lineHeight: 24)) + } } - // MARK: - View Modifier /** 자간을 위한 View Modifier입니다. diff --git a/HappyAnding/HappyAnding/Info.plist b/HappyAnding/HappyAnding/Info.plist index e9717ee2..6fa80349 100644 --- a/HappyAnding/HappyAnding/Info.plist +++ b/HappyAnding/HappyAnding/Info.plist @@ -36,6 +36,10 @@ Pretendard-SemiBold.otf Pretendard-Medium.otf Pretendard-Regular.otf + SF-Compact-Rounded-Bold.otf + SF-Compact-Rounded-Semibold.otf + SF-Compact-Rounded-Medium.otf + SF-Compact-Rounded-Regular.otf diff --git a/HappyAnding/HappyAnding/Resources/SFCompactRounded/SF-Compact-Rounded-Bold.otf b/HappyAnding/HappyAnding/Resources/SFCompactRounded/SF-Compact-Rounded-Bold.otf new file mode 100755 index 00000000..d24e427a Binary files /dev/null and b/HappyAnding/HappyAnding/Resources/SFCompactRounded/SF-Compact-Rounded-Bold.otf differ diff --git a/HappyAnding/HappyAnding/Resources/SFCompactRounded/SF-Compact-Rounded-Medium.otf b/HappyAnding/HappyAnding/Resources/SFCompactRounded/SF-Compact-Rounded-Medium.otf new file mode 100755 index 00000000..604aac22 Binary files /dev/null and b/HappyAnding/HappyAnding/Resources/SFCompactRounded/SF-Compact-Rounded-Medium.otf differ diff --git a/HappyAnding/HappyAnding/Resources/SFCompactRounded/SF-Compact-Rounded-Regular.otf b/HappyAnding/HappyAnding/Resources/SFCompactRounded/SF-Compact-Rounded-Regular.otf new file mode 100755 index 00000000..a9abd5e6 Binary files /dev/null and b/HappyAnding/HappyAnding/Resources/SFCompactRounded/SF-Compact-Rounded-Regular.otf differ diff --git a/HappyAnding/HappyAnding/Resources/SFCompactRounded/SF-Compact-Rounded-Semibold.otf b/HappyAnding/HappyAnding/Resources/SFCompactRounded/SF-Compact-Rounded-Semibold.otf new file mode 100755 index 00000000..5484aa18 Binary files /dev/null and b/HappyAnding/HappyAnding/Resources/SFCompactRounded/SF-Compact-Rounded-Semibold.otf differ