Skip to content

Commit

Permalink
Generate README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
psharanda committed Jan 9, 2024
1 parent ddb50cc commit 515aff3
Show file tree
Hide file tree
Showing 359 changed files with 1,204 additions and 1,006 deletions.
4 changes: 0 additions & 4 deletions FixFlexSamples.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
1B30096D2B1C97A600EA8644 /* Base.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1B30096C2B1C97A600EA8644 /* Base.swift */; };
1B30096F2B1CA61400EA8644 /* StoryViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1B30096E2B1CA61400EA8644 /* StoryViewController.swift */; };
1B3009712B1CAF0600EA8644 /* FixFlexStories.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1B3009702B1CAF0600EA8644 /* FixFlexStories.swift */; };
1B9DA8AA2B2B3917005E256A /* PreviewContainer.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1B9DA8A92B2B3917005E256A /* PreviewContainer.swift */; };
1BDD34892B1BC3A300B19632 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1BDD34882B1BC3A300B19632 /* AppDelegate.swift */; };
1BDD348B2B1BC3A300B19632 /* SceneDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1BDD348A2B1BC3A300B19632 /* SceneDelegate.swift */; };
1BDD348D2B1BC3A300B19632 /* StorybookViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1BDD348C2B1BC3A300B19632 /* StorybookViewController.swift */; };
Expand Down Expand Up @@ -53,7 +52,6 @@
1B30096C2B1C97A600EA8644 /* Base.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Base.swift; sourceTree = "<group>"; };
1B30096E2B1CA61400EA8644 /* StoryViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StoryViewController.swift; sourceTree = "<group>"; };
1B3009702B1CAF0600EA8644 /* FixFlexStories.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FixFlexStories.swift; sourceTree = "<group>"; };
1B9DA8A92B2B3917005E256A /* PreviewContainer.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PreviewContainer.swift; sourceTree = "<group>"; };
1BDD34852B1BC3A300B19632 /* FixFlexSamples.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = FixFlexSamples.app; sourceTree = BUILT_PRODUCTS_DIR; };
1BDD34882B1BC3A300B19632 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
1BDD348A2B1BC3A300B19632 /* SceneDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SceneDelegate.swift; sourceTree = "<group>"; };
Expand Down Expand Up @@ -107,7 +105,6 @@
1B30096C2B1C97A600EA8644 /* Base.swift */,
1BDD348C2B1BC3A300B19632 /* StorybookViewController.swift */,
1B30096E2B1CA61400EA8644 /* StoryViewController.swift */,
1B9DA8A92B2B3917005E256A /* PreviewContainer.swift */,
);
path = Core;
sourceTree = "<group>";
Expand Down Expand Up @@ -275,7 +272,6 @@
files = (
1B30096F2B1CA61400EA8644 /* StoryViewController.swift in Sources */,
1B3009712B1CAF0600EA8644 /* FixFlexStories.swift in Sources */,
1B9DA8AA2B2B3917005E256A /* PreviewContainer.swift in Sources */,
1BDD348D2B1BC3A300B19632 /* StorybookViewController.swift in Sources */,
1B0C13B12B4B556B00846DE4 /* FixFlex.swift in Sources */,
1BDD34892B1BC3A300B19632 /* AppDelegate.swift in Sources */,
Expand Down
14 changes: 14 additions & 0 deletions FixFlexSamples/Core/Base.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,20 @@ import UIKit
struct Story {
let name: String
let makeView: () -> UIView

var nameAsWords: String {
var newString = ""
let letters = Array(name)

for (index, letter) in letters.enumerated() {
if letter.isUppercase && index != 0 {
newString += " "
}
newString += String(letter)
}

return newString
}
}

protocol ComponentStories {
Expand Down
11 changes: 0 additions & 11 deletions FixFlexSamples/Core/PreviewContainer.swift

This file was deleted.

2 changes: 1 addition & 1 deletion FixFlexSamples/Core/StorybookViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ class StorybookViewController: UITableViewController {

override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCell(withIdentifier: "CellId") ?? UITableViewCell()
cell.textLabel?.text = componentsStories[indexPath.section].stories[indexPath.row].name
cell.textLabel?.text = componentsStories[indexPath.section].stories[indexPath.row].nameAsWords
return cell
}

Expand Down
Loading

0 comments on commit 515aff3

Please sign in to comment.