- ShipSwift iOS component template library (public repo)
- Reusable components live under
ShipSwift/SWPackage/in five directories:SWAnimation/— Self-contained animation components (each works independently, may depend on SWUtil only)SWChart/— Self-contained chart components (each works independently, may depend on SWUtil only)SWComponent/— Self-contained UI components organized by category:Display/— Display components (FloatingLabels, MarkdownText, ScrollingFAQ, RotatingQuote, BulletPointText, GradientDivider, Label, OnboardingView, OrderView, RootTabView)Feedback/— Feedback components (Alert, Loading, ThinkingIndicator)Input/— Input components (TabButton, Stepper, AddSheet, SearchBar)
SWModule/— Multi-file frameworks (SWAuth, SWCamera, SWPaywall, SWChat, SWSetting, SWSubjectLifting, SWTikTokTracking)SWUtil/— Shared utilities (no dependencies on other SWPackage directories)
- Showcase app views live under
ShipSwift/View/(HomeView, ModuleListView, AnimationListView, ChartListView, UIListView, ComponentListShared, ProPaywallView, RootTabView, SettingView, ShipSwiftAuthView, SWHolographicCardShowcase) - App services live under
ShipSwift/Service/(ShipSwiftAPIService) - Shared app components live under
ShipSwift/Component/(ListItem)
- All type names use the
SWprefix:SWAlertManager,SWStoreManager,SWCameraView - View modifier methods use
.swlowercase prefix:.swAlert(),.swPageLoading(),.swPrimary - File names match their primary type:
SWAlert.swiftcontainsSWAlertManager - Platform suffix rule: iOS-only files use
+iOSsuffix (e.g.SWCameraManager+iOS.swift), macOS-only files use+macOSsuffix. Cross-platform files have no suffix - Xcode Build Phases reminder: This project supports both iOS and macOS. When adding a
+iOSor+macOSfile, remind the user to set the platform filter in Xcode → Build Phases → Compile Sources (change "Always Used" to "iOS" or "macOS"). Do NOT use#if os(iOS)/#if os(macOS)as a substitute
SWUtilhas zero dependencies on other SWPackage directoriesSWAnimation,SWChart, andSWComponentmay only depend onSWUtilSWModulemay depend onSWUtil,SWComponent, and other files within the same module
- Every file in
SWAnimation/,SWChart/, andSWComponent/must work without importing other SWPackage files (exceptSWUtil) - Alert and Loading merge their managers into the same file for self-containment
- CameraManager uses an
onErrorclosure instead of directly referencingSWAlertManager
- All comments and documentation in English (this is a public repo; overrides the global Chinese rule)
- No external constants file — product IDs, URLs, and config values are inlined or configurable via struct properties
| 标识 | 值 |
|---|---|
| Bundle ID | com.signerlabs.ship-swift-ios |
| Apple ID | 6759209764 |
| App Store Product ID | com.signerlabs.shipswift.lifetime |
| TikTok App ID | 7613007501285818376 |
| SKAdNetwork ID | mj797d8u6f.skadnetwork |
- TikTok 凭证存放在
ShipSwift/SWSecrets.swift(.gitignore,不提交);模板文件SWSecrets.swift.example(提交到 repo)
本库(前端组件模板库)是项目核心资产,任何修改都必须经评审后才可提交。
当 ShipSwift/SWPackage/ 中的组件有任何变更(新增/修改/删除),必须同步更新对应分类的展示页:
| 组件目录 | 展示页文件 |
|---|---|
SWModule/ |
ModuleListView.swift |
SWAnimation/ |
AnimationListView.swift |
SWChart/ |
ChartListView.swift |
SWComponent/(Display / Feedback / Input) |
UIListView.swift |
- 展示页更新后统一评审
- 组件变更后,ShipSwift 服务端的 Recipe 定义也需一并同步(由维护者处理,不在本 repo)
- Skills & Plugin 分发:https://github.com/signerlabs/shipswift-skills