Skip to content

Commit c279bbd

Browse files
first commit
1 parent 7cb7475 commit c279bbd

12 files changed

+410
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"images" : [
3+
{
4+
"filename" : "promocali.jpg",
5+
"idiom" : "universal"
6+
}
7+
],
8+
"info" : {
9+
"author" : "xcode",
10+
"version" : 1
11+
}
12+
}
Loading

Notes/Extras/ButtonPractice.swift

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
//
2+
// ButtonPractice.swift
3+
// Notes
4+
//
5+
// Created by Developer on 24/02/25.
6+
//
7+
8+
import SwiftUI
9+
10+
struct ButtonPractice: View {
11+
var body: some View {
12+
Text(/*@START_MENU_TOKEN@*/"Hello, World!"/*@END_MENU_TOKEN@*/)
13+
}
14+
}
15+
16+
#Preview {
17+
ButtonPractice()
18+
}

Notes/Extras/ExamplesView.swift

+201
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,201 @@
1+
//
2+
// ExamplesView.swift
3+
// Notes
4+
//
5+
// Created by Developer on 24/02/25.
6+
//
7+
8+
import SwiftUI
9+
10+
struct ExamplesView: View {
11+
var body: some View {
12+
// Text("Nunca pares de aprender")
13+
// .font(.system(size: 50))
14+
// .lineLimit(2)
15+
// .multilineTextAlignment(.trailing)
16+
// .bold()
17+
// .underline()
18+
19+
// Circle()
20+
// .background(Color.green)
21+
// .padding()
22+
// .background(Color.red)
23+
// .frame(width: 200, height: 200)
24+
//
25+
// Rectangle()
26+
// .frame(width: 200, height: 200)
27+
// .foregroundStyle(Color.yellow)
28+
// .cornerRadius(20)
29+
// .opacity(0.5)
30+
//
31+
// Ellipse()
32+
// .stroke(lineWidth: 5)
33+
// .frame(width: 200, height: 400)
34+
// .foregroundColor(Color.red)
35+
// .rotationEffect(.degrees(30))
36+
37+
// Button(/*@START_MENU_TOKEN@*/"Button"/*@END_MENU_TOKEN@*/) {
38+
// /*@START_MENU_TOKEN@*//*@PLACEHOLDER=Action@*/ /*@END_MENU_TOKEN@*/
39+
// }.frame(width: 200, height: 50)
40+
// .background(Color.red)
41+
// .foregroundColor(.none)
42+
// Image("logo")
43+
// .resizable()
44+
// .aspectRatio(contentMode: .fit)
45+
// .frame(width: /*@START_MENU_TOKEN@*/100/*@END_MENU_TOKEN@*/, height: 100)
46+
//// .font(.largeTitle)
47+
//// .bold()
48+
// .foregroundStyle(Color.red)
49+
// .background(Color.gray)
50+
51+
// Button(action: {
52+
// print("Button tapped!")
53+
// }) {
54+
// Image(systemName: "heart.fill") // System icon
55+
// .font(.system(size: 24)) // Adjust icon size
56+
// .foregroundColor(.red) // Change icon color
57+
// }.frame(width: 200, height: 50)
58+
// .background(Color.green)
59+
60+
// Removes default button styling
61+
62+
63+
// VStack( alignment: .center, spacing: 20) {
64+
// Text("Nunca")
65+
// Text("pares")
66+
//
67+
// Text("de")
68+
// Text("aprender")
69+
// }
70+
71+
72+
// HStack( alignment: .bottom, spacing: 20) {
73+
// Text("Nunca")
74+
// Text("pares")
75+
// Text("de").font(.largeTitle)
76+
// Text("aprender")
77+
// }
78+
79+
// ZStack( alignment: .center ) {
80+
// Color.green
81+
// Circle()
82+
// HStack(spacing: 0) {
83+
// Rectangle()
84+
// .foregroundStyle(Color.yellow)
85+
// .frame(width: 100, height: 100)
86+
// Rectangle()
87+
// .foregroundStyle(Color.red)
88+
// .frame(width: 100, height: 100)
89+
// }
90+
// VStack() {
91+
// Text("Hola")
92+
// Text("Mundo")
93+
// }
94+
//
95+
// }
96+
97+
VStack(spacing: 20) {
98+
99+
ZStack() {
100+
Rectangle()
101+
.frame(height: /*@START_MENU_TOKEN@*/100/*@END_MENU_TOKEN@*/)
102+
.foregroundColor(.gray.opacity(0.2))
103+
.cornerRadius(20)
104+
105+
HStack(spacing: 20) {
106+
ZStack() {
107+
Rectangle()
108+
.frame(width: 130,height: 40)
109+
.foregroundColor(.blue.opacity(0.2))
110+
.cornerRadius(10)
111+
Text("Hola Mundo").bold()
112+
}
113+
114+
Text("Esto es una card pequeña, saludos")
115+
116+
Image(systemName: "heart").foregroundColor(.red)
117+
}
118+
}
119+
120+
ZStack() {
121+
Rectangle()
122+
.frame(height: 150)
123+
.foregroundColor(.gray.opacity(0.2))
124+
.cornerRadius(20)
125+
126+
VStack() {
127+
VStack() {
128+
HStack {
129+
Spacer()
130+
Image(systemName: "heart")
131+
.foregroundColor(.red)
132+
.padding(.trailing, 10) //
133+
}
134+
ZStack() {
135+
Rectangle()
136+
.frame(width: 130,height: 40)
137+
.foregroundColor(.blue.opacity(0.2))
138+
.cornerRadius(10)
139+
Text("Hola Mundo").bold()
140+
}
141+
}
142+
143+
144+
Text("Esto es una card pequeña, saludos")
145+
146+
}
147+
}
148+
149+
// MARK: Card pequeña
150+
HStack {
151+
Text("Hello, World!")
152+
.font(.headline)
153+
.lineLimit(2)
154+
.frame(width: 120)
155+
.padding(8)
156+
.background(Color.cyan.opacity(0.2))
157+
.cornerRadius(8)
158+
Text("This is an example of a preview.")
159+
.font(.subheadline)
160+
.lineLimit(2)
161+
.multilineTextAlignment(.leading)
162+
.frame(maxWidth: .infinity)
163+
Image(systemName: "heart")
164+
.foregroundStyle(Color.red)
165+
}
166+
.padding()
167+
.background(Color.gray.opacity(0.1))
168+
.cornerRadius(16)
169+
170+
// MARK: Card mediana
171+
VStack {
172+
HStack(alignment: .top) {
173+
Spacer()
174+
Image(systemName: "heart")
175+
.foregroundStyle(Color.red)
176+
}
177+
Text("Hello, World!")
178+
.font(.title2)
179+
.lineLimit(2)
180+
.padding(.vertical, 8)
181+
.padding(.horizontal, 30)
182+
.background(Color.cyan.opacity(0.2))
183+
.cornerRadius(8)
184+
Text("This is an example of a preview.")
185+
.font(.body)
186+
.lineLimit(2)
187+
.multilineTextAlignment(.leading)
188+
.frame(maxWidth: .infinity)
189+
}
190+
.frame(height: 150)
191+
.padding()
192+
.background(Color.gray.opacity(0.1))
193+
.cornerRadius(16)
194+
195+
}.padding()
196+
}
197+
}
198+
199+
#Preview {
200+
ExamplesView()
201+
}

Notes/Extras/PickerPractice.swift

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
//
2+
// PickerPractice.swift
3+
// Notes
4+
//
5+
// Created by Developer on 24/02/25.
6+
//
7+
8+
import SwiftUI
9+
10+
struct PickerPractice: View {
11+
var body: some View {
12+
Text(/*@START_MENU_TOKEN@*/"Hello, World!"/*@END_MENU_TOKEN@*/)
13+
}
14+
}
15+
16+
#Preview {
17+
PickerPractice()
18+
}

Notes/Extras/TextFiledPractice.swift

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
//
2+
// TextFiledPractice.swift
3+
// Notes
4+
//
5+
// Created by Developer on 24/02/25.
6+
//
7+
8+
import SwiftUI
9+
10+
struct TextFiledPractice: View {
11+
var body: some View {
12+
Text(/*@START_MENU_TOKEN@*/"Hello, World!"/*@END_MENU_TOKEN@*/)
13+
}
14+
}
15+
16+
#Preview {
17+
TextFiledPractice()
18+
}

Notes/Extras/TogglePractice.swift

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
//
2+
// TogglePractice.swift
3+
// Notes
4+
//
5+
// Created by Developer on 24/02/25.
6+
//
7+
8+
import SwiftUI
9+
10+
struct TogglePractice: View {
11+
var body: some View {
12+
Text(/*@START_MENU_TOKEN@*/"Hello, World!"/*@END_MENU_TOKEN@*/)
13+
}
14+
}
15+
16+
#Preview {
17+
TogglePractice()
18+
}

Notes/Extras/ViewFunctions.swift

+80
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
//
2+
// ViewFunctions.swift
3+
// Notes
4+
//
5+
// Created by Developer on 24/02/25.
6+
//
7+
8+
import SwiftUI
9+
10+
struct ViewFunctions: View {
11+
@ViewBuilder
12+
func CardSmallView() -> some View {
13+
// MARK: Card pequeña
14+
HStack {
15+
Text("Hello, World!")
16+
.font(.headline)
17+
.lineLimit(2)
18+
.frame(width: 120)
19+
.padding(8)
20+
.background(Color.cyan.opacity(0.2))
21+
.cornerRadius(8)
22+
Text("This is an example of a preview.")
23+
.font(.subheadline)
24+
.lineLimit(2)
25+
.multilineTextAlignment(.leading)
26+
.frame(maxWidth: .infinity)
27+
Image(systemName: "heart")
28+
.foregroundStyle(Color.red)
29+
}
30+
.padding()
31+
.background(Color.gray.opacity(0.1))
32+
.cornerRadius(16)
33+
}
34+
35+
@ViewBuilder
36+
func CardMediumView() -> some View {
37+
// MARK: Card mediana
38+
VStack {
39+
HStack(alignment: .top) {
40+
Spacer()
41+
Image(systemName: "heart")
42+
.foregroundStyle(Color.red)
43+
}
44+
Text("Hello, World!")
45+
.font(.title2)
46+
.lineLimit(2)
47+
.padding(.vertical, 8)
48+
.padding(.horizontal, 30)
49+
.background(Color.cyan.opacity(0.2))
50+
.cornerRadius(8)
51+
Text("This is an example of a preview.")
52+
.font(.body)
53+
.lineLimit(2)
54+
.multilineTextAlignment(.leading)
55+
.frame(maxWidth: .infinity)
56+
}
57+
.frame(height: 150)
58+
.padding()
59+
.background(Color.gray.opacity(0.1))
60+
.cornerRadius(16)
61+
}
62+
63+
var body: some View {
64+
65+
ScrollView(.vertical) {
66+
VStack{
67+
ForEach(0..<64) { _ in
68+
CardSmallView()
69+
CardSmallView()
70+
CardMediumView()
71+
}
72+
73+
}.padding()
74+
}
75+
}
76+
}
77+
78+
#Preview {
79+
ViewFunctions()
80+
}

Notes/Models/NCart.swift

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
//
2+
// NCart.swift
3+
// Notes
4+
//
5+
// Created by Developer on 24/02/25.
6+
//
7+
8+
import Foundation

Notes/Views/NCardView.swift

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
//
2+
// NCardView.swift
3+
// Notes
4+
//
5+
// Created by Developer on 24/02/25.
6+
//
7+
8+
import SwiftUI
9+
10+
struct NCardView: View {
11+
var body: some View {
12+
Text(/*@START_MENU_TOKEN@*/"Hello, World!"/*@END_MENU_TOKEN@*/)
13+
}
14+
}
15+
16+
#Preview {
17+
NCardView()
18+
}

0 commit comments

Comments
 (0)