Skip to content

Commit

Permalink
Merge pull request #72 from boostcampwm-2024/feature/designWhiteboard…
Browse files Browse the repository at this point in the history
…Object

[Feature] 화이트보드 오브젝트, 오브젝트 뷰 설계
  • Loading branch information
taipaise authored Nov 12, 2024
2 parents 9f92b4c + feeff20 commit 9cd9814
Show file tree
Hide file tree
Showing 5 changed files with 97 additions and 0 deletions.
12 changes: 12 additions & 0 deletions Domain/Domain.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

/* Begin PBXBuildFile section */
0080E85B2CE19EBD0095B958 /* DomainStruct.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0080E8582CE19EBD0095B958 /* DomainStruct.swift */; };
0080E8BB2CE2ECD80095B958 /* WhiteboardObject.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0080E8BA2CE2ECC60095B958 /* WhiteboardObject.swift */; };
5B7C6EB02CDB6C040024704A /* AirplaINFoundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 5B7C6EAF2CDB6C040024704A /* AirplaINFoundation.framework */; };
5B7C6EB12CDB6C040024704A /* AirplaINFoundation.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 5B7C6EAF2CDB6C040024704A /* AirplaINFoundation.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
/* End PBXBuildFile section */
Expand All @@ -28,6 +29,7 @@

/* Begin PBXFileReference section */
0080E8582CE19EBD0095B958 /* DomainStruct.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DomainStruct.swift; sourceTree = "<group>"; };
0080E8BA2CE2ECC60095B958 /* WhiteboardObject.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = WhiteboardObject.swift; sourceTree = "<group>"; };
5B7C6E262CDB6A010024704A /* Domain.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Domain.framework; sourceTree = BUILT_PRODUCTS_DIR; };
5B7C6EAF2CDB6C040024704A /* AirplaINFoundation.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; path = AirplaINFoundation.framework; sourceTree = BUILT_PRODUCTS_DIR; };
/* End PBXFileReference section */
Expand All @@ -47,6 +49,7 @@
0080E8592CE19EBD0095B958 /* Sources */ = {
isa = PBXGroup;
children = (
0080E8B92CE2ECB50095B958 /* Entity */,
0080E8582CE19EBD0095B958 /* DomainStruct.swift */,
);
path = Sources;
Expand All @@ -60,6 +63,14 @@
path = Domain;
sourceTree = "<group>";
};
0080E8B92CE2ECB50095B958 /* Entity */ = {
isa = PBXGroup;
children = (
0080E8BA2CE2ECC60095B958 /* WhiteboardObject.swift */,
);
path = Entity;
sourceTree = "<group>";
};
5B7C6E1C2CDB6A010024704A = {
isa = PBXGroup;
children = (
Expand Down Expand Up @@ -193,6 +204,7 @@
buildActionMask = 2147483647;
files = (
0080E85B2CE19EBD0095B958 /* DomainStruct.swift in Sources */,
0080E8BB2CE2ECD80095B958 /* WhiteboardObject.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down
23 changes: 23 additions & 0 deletions Domain/Domain/Sources/Entity/WhiteboardObject.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
//
// WhiteboardObject.swift
// Domain
//
// Created by 이동현 on 11/12/24.
//
import Foundation

public class WhiteboardObject {
public let id: UUID
public var position: CGPoint
public var size: CGSize

public init(
id: UUID,
position: CGPoint,
size: CGSize
) {
self.id = id
self.position = position
self.size = size
}
}
32 changes: 32 additions & 0 deletions Presentation/Presentation.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
objects = {

/* Begin PBXBuildFile section */
0080E8C62CE2F0510095B958 /* WhiteboardObjectView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0080E8C52CE2F04F0095B958 /* WhiteboardObjectView.swift */; };
0080E8CA2CE2FF750095B958 /* WhiteboardObjectViewFactoryable.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0080E8C92CE2FF6E0095B958 /* WhiteboardObjectViewFactoryable.swift */; };
5B7C6EBA2CDB6C5C0024704A /* Domain.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 5B7C6EB92CDB6C5C0024704A /* Domain.framework */; };
5B7C6EBB2CDB6C5C0024704A /* Domain.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 5B7C6EB92CDB6C5C0024704A /* Domain.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
A8525DC32CE200230089DA5E /* Colors.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = A8525DC22CE200230089DA5E /* Colors.xcassets */; };
Expand All @@ -29,6 +31,8 @@
/* End PBXCopyFilesBuildPhase section */

/* Begin PBXFileReference section */
0080E8C52CE2F04F0095B958 /* WhiteboardObjectView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = WhiteboardObjectView.swift; sourceTree = "<group>"; };
0080E8C92CE2FF6E0095B958 /* WhiteboardObjectViewFactoryable.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = WhiteboardObjectViewFactoryable.swift; sourceTree = "<group>"; };
5B7C6E502CDB6A380024704A /* Presentation.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Presentation.framework; sourceTree = BUILT_PRODUCTS_DIR; };
5B7C6EB92CDB6C5C0024704A /* Domain.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; path = Domain.framework; sourceTree = BUILT_PRODUCTS_DIR; };
A8525DC22CE200230089DA5E /* Colors.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Colors.xcassets; sourceTree = "<group>"; };
Expand All @@ -52,6 +56,7 @@
isa = PBXGroup;
children = (
A8525DC52CE201C00089DA5E /* Common */,
0080E8C32CE2F0310095B958 /* Whiteboard */,
);
path = Sources;
sourceTree = "<group>";
Expand All @@ -65,6 +70,31 @@
path = Presentation;
sourceTree = "<group>";
};
0080E8C32CE2F0310095B958 /* Whiteboard */ = {
isa = PBXGroup;
children = (
0080E8C82CE2FF3D0095B958 /* Factory */,
0080E8C42CE2F0430095B958 /* View */,
);
path = Whiteboard;
sourceTree = "<group>";
};
0080E8C42CE2F0430095B958 /* View */ = {
isa = PBXGroup;
children = (
0080E8C52CE2F04F0095B958 /* WhiteboardObjectView.swift */,
);
path = View;
sourceTree = "<group>";
};
0080E8C82CE2FF3D0095B958 /* Factory */ = {
isa = PBXGroup;
children = (
0080E8C92CE2FF6E0095B958 /* WhiteboardObjectViewFactoryable.swift */,
);
path = Factory;
sourceTree = "<group>";
};
5B7C6E462CDB6A380024704A = {
isa = PBXGroup;
children = (
Expand Down Expand Up @@ -229,8 +259,10 @@
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
0080E8C62CE2F0510095B958 /* WhiteboardObjectView.swift in Sources */,
A8525DCB2CE203D50089DA5E /* UIView+.swift in Sources */,
A8525DC82CE201D50089DA5E /* AirplainFont.swift in Sources */,
0080E8CA2CE2FF750095B958 /* WhiteboardObjectViewFactoryable.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
//
// WhiteboardObjectViewFactoryable.swift
// Presentation
//
// Created by 이동현 on 11/12/24.
//
import Domain

protocol WhiteboardObjectViewFactoryable {
func create(with whiteboardObject: WhiteboardObject) -> WhiteboardObjectView
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
//
// WhiteboardObjectView.swift
// Presentation
//
// Created by 이동현 on 11/12/24.
//
import Domain
import UIKit

class WhiteboardObjectView: UIView {
init(whiteboardObject: WhiteboardObject) {
let frame = CGRect(origin: whiteboardObject.position, size: whiteboardObject.size)
super.init(frame: frame)
}

required init?(coder: NSCoder) {
super.init(coder: coder)
}
}

0 comments on commit 9cd9814

Please sign in to comment.