Skip to content

Commit b9de931

Browse files
authored
Update README.md
1 parent 7fdd1e5 commit b9de931

1 file changed

Lines changed: 78 additions & 6 deletions

File tree

README.md

Lines changed: 78 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,19 @@
11
# SwiftNEWKit
22
### Powered by Apple SwiftUI
33

4-
![IMG_3472](https://user-images.githubusercontent.com/54872601/173187065-14d78119-47e7-4dcb-a3e6-c7fee4f0c67f.PNG) | ![IMG_3471](https://user-images.githubusercontent.com/54872601/173187067-fe3b5cac-54b5-4482-b73f-42e6c500546f.PNG)
5-
------------- | ------------
6-
Light Preview | Dark Preview
7-
84
## Aims
95
Provide an easy way for Apple Developers to Show "What's New" to the end users.
106

7+
## Features
8+
- Auto trigger the `.sheet` from Version and/or Build increase
9+
- One-line coding
10+
- JSON compatible
11+
- Versioning
12+
- Local available
13+
- Simple Binding
14+
- Simple Model
15+
- Open source
16+
1117
## Version
1218
![GitHub release (latest by date)](https://img.shields.io/github/v/release/1998code/SwiftNEWKit?color=g&label=STABLE&style=for-the-badge)
1319
![GitHub release (latest by date including pre-releases)](https://img.shields.io/github/v/release/1998code/SwiftNEWKit?color=green&include_prereleases&label=BETA&style=for-the-badge)
@@ -20,7 +26,7 @@ iOS | 16 | > 14
2026
iPadOS | 16 | > 14
2127

2228
## Guide
23-
English | Feel free to add new language(s) via pull requests
29+
[English](https://github.com/1998code/SwiftNEWKit) | Feel free to add new language(s) via `pull requests`
2430

2531
## Get Started
2632
### Full Tutorial:
@@ -43,6 +49,9 @@ size | "normal" | "mini", "normal" | String
4349
label | "Show Release Note" | All Strings | String
4450
labelImage | "arrow.up.circle.fill" | All SF Symbols | String
4551

52+
### Usage
53+
`SwiftNEW(show: $showNew, align: $align, color: $color, size: $size, label: $label, labelImage: $labelImage)`
54+
4655
#### Samples:
4756
```
4857
@State var showNew: Bool = false
@@ -53,8 +62,71 @@ labelImage | "arrow.up.circle.fill" | All SF Symbols | String
5362
@State var labelImage: String = "arrow.up.circle.fill"
5463
```
5564

65+
### JSON
66+
#### Structure / Model
67+
```
68+
public struct Vmodel: Codable, Hashable {
69+
var version: String
70+
var new: [Model]
71+
}
72+
public struct Model: Codable, Hashable {
73+
var icon: String
74+
var title: String
75+
var subtitle: String
76+
var body: String
77+
}
78+
```
79+
### Sample
80+
```
81+
[
82+
{
83+
"version": "1.1",
84+
"new": [{
85+
"icon": "pencil.and.ruler.fill",
86+
"title": "Apple Pencil 3",
87+
"subtitle": "Supported",
88+
"body": "Available for the new iPad Pro"
89+
},
90+
{
91+
"icon": "hammer.fill",
92+
"title": "Bug fixes",
93+
"subtitle": "Broken UI",
94+
"body": "Available for iOS 16, iPadOS 16, macOS 13"
95+
},
96+
{
97+
"icon": "square.and.arrow.down.fill",
98+
"title": "Local File",
99+
"subtitle": "Supported",
100+
"body": "Direct load via local storage. Super fast!"
101+
},
102+
{
103+
"icon": "macpro.gen3.server",
104+
"title": "Serverless",
105+
"subtitle": "Design",
106+
"body": "Free and open source! Created by Ming with ❤️‍🔥"
107+
},
108+
{
109+
"icon": "arrow.triangle.pull",
110+
"title": "Contribute",
111+
"subtitle": "Together",
112+
"body": "Pull requests and make it better for everyone!"
113+
}
114+
]
115+
}
116+
]
117+
```
118+
119+
120+
## Developer Note
121+
-
122+
123+
## Preview
124+
![IMG_3472](https://user-images.githubusercontent.com/54872601/173187065-14d78119-47e7-4dcb-a3e6-c7fee4f0c67f.PNG) | ![IMG_3471](https://user-images.githubusercontent.com/54872601/173187067-fe3b5cac-54b5-4482-b73f-42e6c500546f.PNG)
125+
------------- | ------------
126+
Light Native | Dark Native
127+
56128
## Demo
57-
Path: <code>./Demo</code>
129+
Path: `./Demo`
58130

59131
## License
60132
MIT

0 commit comments

Comments
 (0)