forked from CDS-Mobile1/CDS_iOS
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Feat] CDS-Mobile1#27 - DMTableViewCellHeader 구현
- Loading branch information
1 parent
c272606
commit a726470
Showing
1 changed file
with
43 additions
and
0 deletions.
There are no files selected for viewing
43 changes: 43 additions & 0 deletions
43
Instagram-iOS/Instagram-iOS/Screens/DMList/Cell/DMTableViewCellHeader.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
// | ||
// DMTableViewCellHeader.swift | ||
// Instagram-iOS | ||
// | ||
// Created by Joon Baek on 2023/05/29. | ||
// | ||
|
||
import UIKit | ||
|
||
import SnapKit | ||
|
||
final class DMTableViewCellHeader: UITableViewHeaderFooterView { | ||
|
||
static let identifier = "DMTableViewCellHeader" | ||
|
||
private let sectionLabel: UILabel = { | ||
let label = UILabel() | ||
label.font = .bodyKorBold | ||
label.textColor = .black1 | ||
label.text = "메시지" | ||
return label | ||
}() | ||
|
||
override init(reuseIdentifier: String?) { | ||
super.init(reuseIdentifier: reuseIdentifier) | ||
|
||
setLayout() | ||
} | ||
|
||
required init?(coder: NSCoder) { | ||
fatalError("init(coder:) has not been implemented") | ||
} | ||
|
||
private func setLayout() { | ||
|
||
addSubview(sectionLabel) | ||
|
||
sectionLabel.snp.makeConstraints { | ||
$0.leading.equalToSuperview().offset(16) | ||
$0.bottom.equalToSuperview().offset(-8) | ||
} | ||
} | ||
} |