├── .gitignore ├── .swift-version ├── DocsAssets ├── ButtonExample.png ├── InitialsViewExample.png ├── LabelExample.png ├── LogoViewExample.png └── TextFieldExample.png ├── LICENSE ├── OfficeUIFabricCore.podspec ├── OfficeUIFabricCore ├── OfficeUIFabricCore.xcodeproj │ ├── project.pbxproj │ └── project.xcworkspace │ │ └── contents.xcworkspacedata └── OfficeUIFabricCore │ ├── Components │ └── Common │ │ ├── InitialsView │ │ ├── InitialsView.swift │ │ └── StringInitialsExtension.swift │ │ └── LogoView │ │ └── LogoView.swift │ ├── Core │ ├── Colors │ │ ├── UIColorMSExtension.swift │ │ └── UIColorMSHashExtension.swift │ └── Typography │ │ ├── MSFontConstants.swift │ │ └── UIFontMSExtension.swift │ ├── Customization │ ├── UIButton │ │ ├── UIButtonMSExtension.swift │ │ └── UIImageMSButtonExtension.swift │ ├── UILabel │ │ └── UILabelMSExtension.swift │ └── UITextField │ │ ├── UIImageMSTextFieldExtension.swift │ │ ├── UITextFieldConstants.swift │ │ └── UITextFieldMSExtension.swift │ ├── Info.plist │ └── OfficeUIFabricCore.h ├── OfficeUIFabricDemo ├── OfficeUIFabricDemo.xcodeproj │ ├── project.pbxproj │ └── project.xcworkspace │ │ └── contents.xcworkspacedata ├── OfficeUIFabricDemo.xcworkspace │ └── contents.xcworkspacedata └── OfficeUIFabricDemo │ ├── AppDelegate.swift │ ├── Assets.xcassets │ ├── AppIcon.appiconset │ │ ├── Contents.json │ │ ├── OfficeUIFabric29.png │ │ ├── OfficeUIFabric29@2x-1.png │ │ ├── OfficeUIFabric29@2x.png │ │ ├── OfficeUIFabric29@3x.png │ │ ├── OfficeUIFabric40.png │ │ ├── OfficeUIFabric40@2x-1.png │ │ ├── OfficeUIFabric40@2x.png │ │ ├── OfficeUIFabric40@3x.png │ │ ├── OfficeUIFabric60@2x.png │ │ ├── OfficeUIFabric60@3x.png │ │ ├── OfficeUIFabric76.png │ │ ├── OfficeUIFabric76@2x.png │ │ └── OfficeUIFabric83.5@2x.png │ ├── CircleIcon.imageset │ │ ├── CircleIcon.png │ │ ├── CircleIcon@2x.png │ │ ├── CircleIcon@3x.png │ │ └── Contents.json │ ├── CircleIconFilled.imageset │ │ ├── CircleIconFilled.png │ │ ├── CircleIconFilled@2x.png │ │ ├── CircleIconFilled@3x.png │ │ └── Contents.json │ ├── Contents.json │ ├── OfficeUIFabric.Person.imageset │ │ ├── Contents.json │ │ └── OfficeUIFabric.Person.png │ └── OfficeUIFabric.TestImage.imageset │ │ ├── Contents.json │ │ ├── OfficeUIFabric.TestImage.png │ │ ├── OfficeUIFabric.TestImage@2x.png │ │ └── OfficeUIFabric.TestImage@3x.png │ ├── Base.lproj │ ├── LaunchScreen.storyboard │ └── Main.storyboard │ ├── DemoControllers │ ├── Colors │ │ ├── ColorItemCell.swift │ │ ├── ColorPaletteTableViewController.swift │ │ ├── ColorsDataSource.swift │ │ ├── ColorsSectionHeader.swift │ │ └── ColorsSectionHeader.xib │ ├── Components │ │ ├── InitialsView │ │ │ ├── InitialsView.storyboard │ │ │ ├── InitialsViewItemCell.swift │ │ │ └── InitialsViewTableViewController.swift │ │ └── LogoView │ │ │ ├── LogoView.storyboard │ │ │ ├── LogoViewItemCell.swift │ │ │ └── LogoViewTableViewController.swift │ ├── Customization │ │ ├── ButtonDemoViewController.swift │ │ ├── LabelDemoViewController.swift │ │ └── TextFieldDemoViewController.swift │ ├── Fonts │ │ ├── FontItemCell.swift │ │ └── FontsTableViewController.swift │ └── Main │ │ ├── DemoItemCell.swift │ │ ├── DemoSectionHeader.swift │ │ ├── DemoSectionHeader.xib │ │ └── MainTableViewController.swift │ └── Info.plist └── README.md /.gitignore: -------------------------------------------------------------------------------- 1 | ## Xcode 2 | build/ 3 | DerivedData 4 | 5 | ## Various settings 6 | *.pbxuser 7 | !default.pbxuser 8 | *.mode1v3 9 | !default.mode1v3 10 | *.mode2v3 11 | !default.mode2v3 12 | *.perspectivev3 13 | !default.perspectivev3 14 | xcuserdata 15 | 16 | ## Other 17 | *.xccheckout 18 | *.moved-aside 19 | *.xcuserstate 20 | *.xcscmblueprint 21 | 22 | ## Obj-C/Swift specific 23 | *.hmap 24 | *.ipa 25 | 26 | # Swift Package Manager 27 | .build/ 28 | 29 | # CocoaPods 30 | Pods/ 31 | 32 | # Carthage 33 | Carthage/Checkouts 34 | Carthage/Build 35 | -------------------------------------------------------------------------------- /.swift-version: -------------------------------------------------------------------------------- 1 | 3.0 -------------------------------------------------------------------------------- /DocsAssets/ButtonExample.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/DocsAssets/ButtonExample.png -------------------------------------------------------------------------------- /DocsAssets/InitialsViewExample.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/DocsAssets/InitialsViewExample.png -------------------------------------------------------------------------------- /DocsAssets/LabelExample.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/DocsAssets/LabelExample.png -------------------------------------------------------------------------------- /DocsAssets/LogoViewExample.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/DocsAssets/LogoViewExample.png -------------------------------------------------------------------------------- /DocsAssets/TextFieldExample.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/DocsAssets/TextFieldExample.png -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Office UI Fabric iOS 2 | 3 | Copyright (c) Microsoft Corporation 4 | 5 | All rights reserved. 6 | 7 | MIT License 8 | 9 | Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the ""Software""), 10 | to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, 11 | and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS 18 | IN THE SOFTWARE. -------------------------------------------------------------------------------- /OfficeUIFabricCore.podspec: -------------------------------------------------------------------------------- 1 | Pod::Spec.new do |s| 2 | s.name = "OfficeUIFabricCore" 3 | s.version = "0.2.1" 4 | s.summary = "The iOS UI framework for building experiences for Office and Office 365" 5 | s.description = <<-DESC 6 | Fabric for iOS is a library that provides the Office UI experience for the native iOS platform. It contains tokens like Colors and Typography, as well as customization for native controls. All from the official design language used in Office and Office 365 products. 7 | DESC 8 | s.homepage = "https://github.com/OfficeDev/Office-UI-Fabric-iOS" 9 | s.documentation_url = "http://dev.office.com/fabric/styles" 10 | s.license = { :type => "MIT", :file => "LICENSE" } 11 | 12 | s.author = { "Andrew Cherkashyn" => "v-cheand@microsoft.com" } 13 | 14 | s.platform = :ios, "9.0" 15 | s.ios.deployment_target = '9.0' 16 | s.requires_arc = true 17 | 18 | s.source = { :git => "https://github.com/OfficeDev/Office-UI-Fabric-iOS.git", :tag => s.version.to_s } 19 | s.source_files = "OfficeUIFabricCore/OfficeUIFabricCore/{Core,Components,Customization}/**/*" 20 | s.framework = "UIKit" 21 | end 22 | -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | A635549E1CA4ABFC00B33AF2 /* UIButtonMSExtension.swift in Sources */ = {isa = PBXBuildFile; fileRef = A635549D1CA4ABFC00B33AF2 /* UIButtonMSExtension.swift */; }; 11 | A63554A01CA4AD0700B33AF2 /* UIImageMSButtonExtension.swift in Sources */ = {isa = PBXBuildFile; fileRef = A635549F1CA4AD0700B33AF2 /* UIImageMSButtonExtension.swift */; }; 12 | A63554A61CA5E79000B33AF2 /* UILabelMSExtension.swift in Sources */ = {isa = PBXBuildFile; fileRef = A63554A51CA5E79000B33AF2 /* UILabelMSExtension.swift */; }; 13 | A63554AD1CA9AEB600B33AF2 /* UITextFieldMSExtension.swift in Sources */ = {isa = PBXBuildFile; fileRef = A63554AC1CA9AEB600B33AF2 /* UITextFieldMSExtension.swift */; }; 14 | A63554AF1CA9B1A700B33AF2 /* UITextFieldConstants.swift in Sources */ = {isa = PBXBuildFile; fileRef = A63554AE1CA9B1A700B33AF2 /* UITextFieldConstants.swift */; }; 15 | A63554B11CA9B2EB00B33AF2 /* UIImageMSTextFieldExtension.swift in Sources */ = {isa = PBXBuildFile; fileRef = A63554B01CA9B2EB00B33AF2 /* UIImageMSTextFieldExtension.swift */; }; 16 | A6371F8C1C6272560086CB29 /* OfficeUIFabricCore.h in Headers */ = {isa = PBXBuildFile; fileRef = A6371F8B1C6272560086CB29 /* OfficeUIFabricCore.h */; settings = {ATTRIBUTES = (Public, ); }; }; 17 | A6371F9D1C6275970086CB29 /* UIColorMSExtension.swift in Sources */ = {isa = PBXBuildFile; fileRef = A6371F951C6275970086CB29 /* UIColorMSExtension.swift */; }; 18 | A6371F9E1C6275970086CB29 /* UIColorMSHashExtension.swift in Sources */ = {isa = PBXBuildFile; fileRef = A6371F961C6275970086CB29 /* UIColorMSHashExtension.swift */; }; 19 | A6371FA11C6275970086CB29 /* MSFontConstants.swift in Sources */ = {isa = PBXBuildFile; fileRef = A6371F9B1C6275970086CB29 /* MSFontConstants.swift */; }; 20 | A6371FA21C6275970086CB29 /* UIFontMSExtension.swift in Sources */ = {isa = PBXBuildFile; fileRef = A6371F9C1C6275970086CB29 /* UIFontMSExtension.swift */; }; 21 | A657A4D01C87959D007B2414 /* InitialsView.swift in Sources */ = {isa = PBXBuildFile; fileRef = A657A4CF1C87959D007B2414 /* InitialsView.swift */; }; 22 | A657A4D21C87964B007B2414 /* StringInitialsExtension.swift in Sources */ = {isa = PBXBuildFile; fileRef = A657A4D11C87964B007B2414 /* StringInitialsExtension.swift */; }; 23 | A657A4E01C87B752007B2414 /* LogoView.swift in Sources */ = {isa = PBXBuildFile; fileRef = A657A4DF1C87B752007B2414 /* LogoView.swift */; }; 24 | /* End PBXBuildFile section */ 25 | 26 | /* Begin PBXFileReference section */ 27 | A635549D1CA4ABFC00B33AF2 /* UIButtonMSExtension.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = UIButtonMSExtension.swift; sourceTree = ""; }; 28 | A635549F1CA4AD0700B33AF2 /* UIImageMSButtonExtension.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = UIImageMSButtonExtension.swift; sourceTree = ""; }; 29 | A63554A51CA5E79000B33AF2 /* UILabelMSExtension.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = UILabelMSExtension.swift; sourceTree = ""; }; 30 | A63554AC1CA9AEB600B33AF2 /* UITextFieldMSExtension.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = UITextFieldMSExtension.swift; sourceTree = ""; }; 31 | A63554AE1CA9B1A700B33AF2 /* UITextFieldConstants.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = UITextFieldConstants.swift; sourceTree = ""; }; 32 | A63554B01CA9B2EB00B33AF2 /* UIImageMSTextFieldExtension.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = UIImageMSTextFieldExtension.swift; sourceTree = ""; }; 33 | A6371F881C6272560086CB29 /* OfficeUIFabricCore.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = OfficeUIFabricCore.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 34 | A6371F8B1C6272560086CB29 /* OfficeUIFabricCore.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = OfficeUIFabricCore.h; sourceTree = ""; }; 35 | A6371F8D1C6272560086CB29 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 36 | A6371F951C6275970086CB29 /* UIColorMSExtension.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = UIColorMSExtension.swift; sourceTree = ""; }; 37 | A6371F961C6275970086CB29 /* UIColorMSHashExtension.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = UIColorMSHashExtension.swift; sourceTree = ""; }; 38 | A6371F9B1C6275970086CB29 /* MSFontConstants.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = MSFontConstants.swift; sourceTree = ""; }; 39 | A6371F9C1C6275970086CB29 /* UIFontMSExtension.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = UIFontMSExtension.swift; sourceTree = ""; }; 40 | A657A4CF1C87959D007B2414 /* InitialsView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = InitialsView.swift; sourceTree = ""; }; 41 | A657A4D11C87964B007B2414 /* StringInitialsExtension.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = StringInitialsExtension.swift; sourceTree = ""; }; 42 | A657A4DF1C87B752007B2414 /* LogoView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = LogoView.swift; sourceTree = ""; }; 43 | /* End PBXFileReference section */ 44 | 45 | /* Begin PBXFrameworksBuildPhase section */ 46 | A6371F841C6272560086CB29 /* Frameworks */ = { 47 | isa = PBXFrameworksBuildPhase; 48 | buildActionMask = 2147483647; 49 | files = ( 50 | ); 51 | runOnlyForDeploymentPostprocessing = 0; 52 | }; 53 | /* End PBXFrameworksBuildPhase section */ 54 | 55 | /* Begin PBXGroup section */ 56 | A635549B1CA4ABC500B33AF2 /* Customization */ = { 57 | isa = PBXGroup; 58 | children = ( 59 | A635549C1CA4ABE200B33AF2 /* UIButton */, 60 | A63554A41CA5E76C00B33AF2 /* UILabel */, 61 | A63554AB1CA9AE9300B33AF2 /* UITextField */, 62 | ); 63 | path = Customization; 64 | sourceTree = ""; 65 | }; 66 | A635549C1CA4ABE200B33AF2 /* UIButton */ = { 67 | isa = PBXGroup; 68 | children = ( 69 | A635549D1CA4ABFC00B33AF2 /* UIButtonMSExtension.swift */, 70 | A635549F1CA4AD0700B33AF2 /* UIImageMSButtonExtension.swift */, 71 | ); 72 | path = UIButton; 73 | sourceTree = ""; 74 | }; 75 | A63554A41CA5E76C00B33AF2 /* UILabel */ = { 76 | isa = PBXGroup; 77 | children = ( 78 | A63554A51CA5E79000B33AF2 /* UILabelMSExtension.swift */, 79 | ); 80 | path = UILabel; 81 | sourceTree = ""; 82 | }; 83 | A63554AB1CA9AE9300B33AF2 /* UITextField */ = { 84 | isa = PBXGroup; 85 | children = ( 86 | A63554AC1CA9AEB600B33AF2 /* UITextFieldMSExtension.swift */, 87 | A63554AE1CA9B1A700B33AF2 /* UITextFieldConstants.swift */, 88 | A63554B01CA9B2EB00B33AF2 /* UIImageMSTextFieldExtension.swift */, 89 | ); 90 | path = UITextField; 91 | sourceTree = ""; 92 | }; 93 | A6371F7E1C6272560086CB29 = { 94 | isa = PBXGroup; 95 | children = ( 96 | A6371F8A1C6272560086CB29 /* OfficeUIFabricCore */, 97 | A6371F891C6272560086CB29 /* Products */, 98 | ); 99 | sourceTree = ""; 100 | }; 101 | A6371F891C6272560086CB29 /* Products */ = { 102 | isa = PBXGroup; 103 | children = ( 104 | A6371F881C6272560086CB29 /* OfficeUIFabricCore.framework */, 105 | ); 106 | name = Products; 107 | sourceTree = ""; 108 | }; 109 | A6371F8A1C6272560086CB29 /* OfficeUIFabricCore */ = { 110 | isa = PBXGroup; 111 | children = ( 112 | A657A4C91C8792EC007B2414 /* Components */, 113 | A6371F931C6275970086CB29 /* Core */, 114 | A635549B1CA4ABC500B33AF2 /* Customization */, 115 | A6371F8B1C6272560086CB29 /* OfficeUIFabricCore.h */, 116 | A6371F8D1C6272560086CB29 /* Info.plist */, 117 | ); 118 | path = OfficeUIFabricCore; 119 | sourceTree = ""; 120 | }; 121 | A6371F931C6275970086CB29 /* Core */ = { 122 | isa = PBXGroup; 123 | children = ( 124 | A6371F941C6275970086CB29 /* Colors */, 125 | A6371F9A1C6275970086CB29 /* Typography */, 126 | ); 127 | path = Core; 128 | sourceTree = ""; 129 | }; 130 | A6371F941C6275970086CB29 /* Colors */ = { 131 | isa = PBXGroup; 132 | children = ( 133 | A6371F951C6275970086CB29 /* UIColorMSExtension.swift */, 134 | A6371F961C6275970086CB29 /* UIColorMSHashExtension.swift */, 135 | ); 136 | path = Colors; 137 | sourceTree = ""; 138 | }; 139 | A6371F9A1C6275970086CB29 /* Typography */ = { 140 | isa = PBXGroup; 141 | children = ( 142 | A6371F9B1C6275970086CB29 /* MSFontConstants.swift */, 143 | A6371F9C1C6275970086CB29 /* UIFontMSExtension.swift */, 144 | ); 145 | path = Typography; 146 | sourceTree = ""; 147 | }; 148 | A657A4C91C8792EC007B2414 /* Components */ = { 149 | isa = PBXGroup; 150 | children = ( 151 | A657A4CD1C87958E007B2414 /* Common */, 152 | ); 153 | path = Components; 154 | sourceTree = ""; 155 | }; 156 | A657A4CD1C87958E007B2414 /* Common */ = { 157 | isa = PBXGroup; 158 | children = ( 159 | A657A4CE1C87958E007B2414 /* InitialsView */, 160 | A657A4DE1C87B726007B2414 /* LogoView */, 161 | ); 162 | path = Common; 163 | sourceTree = ""; 164 | }; 165 | A657A4CE1C87958E007B2414 /* InitialsView */ = { 166 | isa = PBXGroup; 167 | children = ( 168 | A657A4CF1C87959D007B2414 /* InitialsView.swift */, 169 | A657A4D11C87964B007B2414 /* StringInitialsExtension.swift */, 170 | ); 171 | path = InitialsView; 172 | sourceTree = ""; 173 | }; 174 | A657A4DE1C87B726007B2414 /* LogoView */ = { 175 | isa = PBXGroup; 176 | children = ( 177 | A657A4DF1C87B752007B2414 /* LogoView.swift */, 178 | ); 179 | path = LogoView; 180 | sourceTree = ""; 181 | }; 182 | /* End PBXGroup section */ 183 | 184 | /* Begin PBXHeadersBuildPhase section */ 185 | A6371F851C6272560086CB29 /* Headers */ = { 186 | isa = PBXHeadersBuildPhase; 187 | buildActionMask = 2147483647; 188 | files = ( 189 | A6371F8C1C6272560086CB29 /* OfficeUIFabricCore.h in Headers */, 190 | ); 191 | runOnlyForDeploymentPostprocessing = 0; 192 | }; 193 | /* End PBXHeadersBuildPhase section */ 194 | 195 | /* Begin PBXNativeTarget section */ 196 | A6371F871C6272560086CB29 /* OfficeUIFabricCore */ = { 197 | isa = PBXNativeTarget; 198 | buildConfigurationList = A6371F901C6272560086CB29 /* Build configuration list for PBXNativeTarget "OfficeUIFabricCore" */; 199 | buildPhases = ( 200 | A6371F831C6272560086CB29 /* Sources */, 201 | A6371F841C6272560086CB29 /* Frameworks */, 202 | A6371F851C6272560086CB29 /* Headers */, 203 | A6371F861C6272560086CB29 /* Resources */, 204 | ); 205 | buildRules = ( 206 | ); 207 | dependencies = ( 208 | ); 209 | name = OfficeUIFabricCore; 210 | productName = OfficeUIFabricCore; 211 | productReference = A6371F881C6272560086CB29 /* OfficeUIFabricCore.framework */; 212 | productType = "com.apple.product-type.framework"; 213 | }; 214 | /* End PBXNativeTarget section */ 215 | 216 | /* Begin PBXProject section */ 217 | A6371F7F1C6272560086CB29 /* Project object */ = { 218 | isa = PBXProject; 219 | attributes = { 220 | LastUpgradeCheck = 0800; 221 | ORGANIZATIONNAME = Microsoft; 222 | TargetAttributes = { 223 | A6371F871C6272560086CB29 = { 224 | CreatedOnToolsVersion = 7.2; 225 | LastSwiftMigration = 0800; 226 | }; 227 | }; 228 | }; 229 | buildConfigurationList = A6371F821C6272560086CB29 /* Build configuration list for PBXProject "OfficeUIFabricCore" */; 230 | compatibilityVersion = "Xcode 3.2"; 231 | developmentRegion = English; 232 | hasScannedForEncodings = 0; 233 | knownRegions = ( 234 | en, 235 | ); 236 | mainGroup = A6371F7E1C6272560086CB29; 237 | productRefGroup = A6371F891C6272560086CB29 /* Products */; 238 | projectDirPath = ""; 239 | projectRoot = ""; 240 | targets = ( 241 | A6371F871C6272560086CB29 /* OfficeUIFabricCore */, 242 | ); 243 | }; 244 | /* End PBXProject section */ 245 | 246 | /* Begin PBXResourcesBuildPhase section */ 247 | A6371F861C6272560086CB29 /* Resources */ = { 248 | isa = PBXResourcesBuildPhase; 249 | buildActionMask = 2147483647; 250 | files = ( 251 | ); 252 | runOnlyForDeploymentPostprocessing = 0; 253 | }; 254 | /* End PBXResourcesBuildPhase section */ 255 | 256 | /* Begin PBXSourcesBuildPhase section */ 257 | A6371F831C6272560086CB29 /* Sources */ = { 258 | isa = PBXSourcesBuildPhase; 259 | buildActionMask = 2147483647; 260 | files = ( 261 | A657A4D01C87959D007B2414 /* InitialsView.swift in Sources */, 262 | A657A4D21C87964B007B2414 /* StringInitialsExtension.swift in Sources */, 263 | A63554AD1CA9AEB600B33AF2 /* UITextFieldMSExtension.swift in Sources */, 264 | A63554A01CA4AD0700B33AF2 /* UIImageMSButtonExtension.swift in Sources */, 265 | A6371FA21C6275970086CB29 /* UIFontMSExtension.swift in Sources */, 266 | A635549E1CA4ABFC00B33AF2 /* UIButtonMSExtension.swift in Sources */, 267 | A6371FA11C6275970086CB29 /* MSFontConstants.swift in Sources */, 268 | A657A4E01C87B752007B2414 /* LogoView.swift in Sources */, 269 | A6371F9D1C6275970086CB29 /* UIColorMSExtension.swift in Sources */, 270 | A63554AF1CA9B1A700B33AF2 /* UITextFieldConstants.swift in Sources */, 271 | A63554A61CA5E79000B33AF2 /* UILabelMSExtension.swift in Sources */, 272 | A63554B11CA9B2EB00B33AF2 /* UIImageMSTextFieldExtension.swift in Sources */, 273 | A6371F9E1C6275970086CB29 /* UIColorMSHashExtension.swift in Sources */, 274 | ); 275 | runOnlyForDeploymentPostprocessing = 0; 276 | }; 277 | /* End PBXSourcesBuildPhase section */ 278 | 279 | /* Begin XCBuildConfiguration section */ 280 | A6371F8E1C6272560086CB29 /* Debug */ = { 281 | isa = XCBuildConfiguration; 282 | buildSettings = { 283 | ALWAYS_SEARCH_USER_PATHS = NO; 284 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 285 | CLANG_CXX_LIBRARY = "libc++"; 286 | CLANG_ENABLE_MODULES = YES; 287 | CLANG_ENABLE_OBJC_ARC = YES; 288 | CLANG_WARN_BOOL_CONVERSION = YES; 289 | CLANG_WARN_CONSTANT_CONVERSION = YES; 290 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 291 | CLANG_WARN_EMPTY_BODY = YES; 292 | CLANG_WARN_ENUM_CONVERSION = YES; 293 | CLANG_WARN_INFINITE_RECURSION = YES; 294 | CLANG_WARN_INT_CONVERSION = YES; 295 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 296 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 297 | CLANG_WARN_UNREACHABLE_CODE = YES; 298 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 299 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 300 | COPY_PHASE_STRIP = NO; 301 | CURRENT_PROJECT_VERSION = 1; 302 | DEBUG_INFORMATION_FORMAT = dwarf; 303 | ENABLE_STRICT_OBJC_MSGSEND = YES; 304 | ENABLE_TESTABILITY = YES; 305 | GCC_C_LANGUAGE_STANDARD = gnu99; 306 | GCC_DYNAMIC_NO_PIC = NO; 307 | GCC_NO_COMMON_BLOCKS = YES; 308 | GCC_OPTIMIZATION_LEVEL = 0; 309 | GCC_PREPROCESSOR_DEFINITIONS = ( 310 | "DEBUG=1", 311 | "$(inherited)", 312 | ); 313 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 314 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 315 | GCC_WARN_UNDECLARED_SELECTOR = YES; 316 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 317 | GCC_WARN_UNUSED_FUNCTION = YES; 318 | GCC_WARN_UNUSED_VARIABLE = YES; 319 | IPHONEOS_DEPLOYMENT_TARGET = 9.2; 320 | MTL_ENABLE_DEBUG_INFO = YES; 321 | ONLY_ACTIVE_ARCH = YES; 322 | SDKROOT = iphoneos; 323 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 324 | TARGETED_DEVICE_FAMILY = "1,2"; 325 | VERSIONING_SYSTEM = "apple-generic"; 326 | VERSION_INFO_PREFIX = ""; 327 | }; 328 | name = Debug; 329 | }; 330 | A6371F8F1C6272560086CB29 /* Release */ = { 331 | isa = XCBuildConfiguration; 332 | buildSettings = { 333 | ALWAYS_SEARCH_USER_PATHS = NO; 334 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 335 | CLANG_CXX_LIBRARY = "libc++"; 336 | CLANG_ENABLE_MODULES = YES; 337 | CLANG_ENABLE_OBJC_ARC = YES; 338 | CLANG_WARN_BOOL_CONVERSION = YES; 339 | CLANG_WARN_CONSTANT_CONVERSION = YES; 340 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 341 | CLANG_WARN_EMPTY_BODY = YES; 342 | CLANG_WARN_ENUM_CONVERSION = YES; 343 | CLANG_WARN_INFINITE_RECURSION = YES; 344 | CLANG_WARN_INT_CONVERSION = YES; 345 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 346 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 347 | CLANG_WARN_UNREACHABLE_CODE = YES; 348 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 349 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 350 | COPY_PHASE_STRIP = NO; 351 | CURRENT_PROJECT_VERSION = 1; 352 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 353 | ENABLE_NS_ASSERTIONS = NO; 354 | ENABLE_STRICT_OBJC_MSGSEND = YES; 355 | GCC_C_LANGUAGE_STANDARD = gnu99; 356 | GCC_NO_COMMON_BLOCKS = YES; 357 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 358 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 359 | GCC_WARN_UNDECLARED_SELECTOR = YES; 360 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 361 | GCC_WARN_UNUSED_FUNCTION = YES; 362 | GCC_WARN_UNUSED_VARIABLE = YES; 363 | IPHONEOS_DEPLOYMENT_TARGET = 9.2; 364 | MTL_ENABLE_DEBUG_INFO = NO; 365 | SDKROOT = iphoneos; 366 | SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; 367 | TARGETED_DEVICE_FAMILY = "1,2"; 368 | VALIDATE_PRODUCT = YES; 369 | VERSIONING_SYSTEM = "apple-generic"; 370 | VERSION_INFO_PREFIX = ""; 371 | }; 372 | name = Release; 373 | }; 374 | A6371F911C6272560086CB29 /* Debug */ = { 375 | isa = XCBuildConfiguration; 376 | buildSettings = { 377 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; 378 | DEFINES_MODULE = YES; 379 | DYLIB_COMPATIBILITY_VERSION = 1; 380 | DYLIB_CURRENT_VERSION = 1; 381 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 382 | INFOPLIST_FILE = OfficeUIFabricCore/Info.plist; 383 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 384 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 385 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 386 | PRODUCT_BUNDLE_IDENTIFIER = "com.officeui-fabric.OfficeUIFabricCore"; 387 | PRODUCT_NAME = "$(TARGET_NAME)"; 388 | SKIP_INSTALL = YES; 389 | SWIFT_VERSION = 3.0; 390 | }; 391 | name = Debug; 392 | }; 393 | A6371F921C6272560086CB29 /* Release */ = { 394 | isa = XCBuildConfiguration; 395 | buildSettings = { 396 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; 397 | DEFINES_MODULE = YES; 398 | DYLIB_COMPATIBILITY_VERSION = 1; 399 | DYLIB_CURRENT_VERSION = 1; 400 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 401 | INFOPLIST_FILE = OfficeUIFabricCore/Info.plist; 402 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 403 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 404 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 405 | PRODUCT_BUNDLE_IDENTIFIER = "com.officeui-fabric.OfficeUIFabricCore"; 406 | PRODUCT_NAME = "$(TARGET_NAME)"; 407 | SKIP_INSTALL = YES; 408 | SWIFT_VERSION = 3.0; 409 | }; 410 | name = Release; 411 | }; 412 | /* End XCBuildConfiguration section */ 413 | 414 | /* Begin XCConfigurationList section */ 415 | A6371F821C6272560086CB29 /* Build configuration list for PBXProject "OfficeUIFabricCore" */ = { 416 | isa = XCConfigurationList; 417 | buildConfigurations = ( 418 | A6371F8E1C6272560086CB29 /* Debug */, 419 | A6371F8F1C6272560086CB29 /* Release */, 420 | ); 421 | defaultConfigurationIsVisible = 0; 422 | defaultConfigurationName = Release; 423 | }; 424 | A6371F901C6272560086CB29 /* Build configuration list for PBXNativeTarget "OfficeUIFabricCore" */ = { 425 | isa = XCConfigurationList; 426 | buildConfigurations = ( 427 | A6371F911C6272560086CB29 /* Debug */, 428 | A6371F921C6272560086CB29 /* Release */, 429 | ); 430 | defaultConfigurationIsVisible = 0; 431 | defaultConfigurationName = Release; 432 | }; 433 | /* End XCConfigurationList section */ 434 | }; 435 | rootObject = A6371F7F1C6272560086CB29 /* Project object */; 436 | } 437 | -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore/Components/Common/InitialsView/InitialsView.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | open class InitialsView: UIView { 6 | private(set) open var initialsLabel: UILabel = UILabel() 7 | 8 | // MARK: Initialization 9 | 10 | public convenience init() { 11 | self.init(frame: CGRect.zero) 12 | } 13 | 14 | override public init(frame: CGRect) { 15 | super.init(frame: frame) 16 | self.setUpInitialsLabel() 17 | } 18 | 19 | required public init?(coder aDecoder: NSCoder) { 20 | super.init(coder: aDecoder) 21 | self.setUpInitialsLabel() 22 | } 23 | 24 | private func setUpInitialsLabel() { 25 | self.initialsLabel.frame = self.bounds 26 | self.initialsLabel.textAlignment = .center 27 | self.initialsLabel.translatesAutoresizingMaskIntoConstraints = false 28 | self.initialsLabel.font = UIFont.msFont(style: MSFontStyle.XL, weight: MSFontWeight.Regular) 29 | self.initialsLabel.textColor = UIColor.msNeutralWhite() 30 | self.initialsLabel.clipsToBounds = true 31 | self.addSubview(self.initialsLabel) 32 | self.setUpConstraints() 33 | } 34 | 35 | private func setUpConstraints() { 36 | let views = ["label": self.initialsLabel] 37 | 38 | let horizontalConstraints = NSLayoutConstraint.constraints(withVisualFormat: "H:|-0-[label]-0-|", options: NSLayoutFormatOptions.alignAllCenterX, metrics: nil, views: views) 39 | self.addConstraints(horizontalConstraints) 40 | 41 | let verticalConstraints = NSLayoutConstraint.constraints(withVisualFormat: "V:|-0-[label]-0-|", options: NSLayoutFormatOptions.alignAllCenterY, metrics: nil, views: views) 42 | self.addConstraints(verticalConstraints) 43 | } 44 | 45 | // MARK: Usage 46 | 47 | open func setInitialsFromTitle(title: String) { 48 | self.initialsLabel.text = title.initials().uppercased() 49 | self.backgroundColor = UIColor.msHashColor(hash: title) 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore/Components/Common/InitialsView/StringInitialsExtension.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | extension String { 6 | internal func words() -> [String] { 7 | let range = self.startIndex.. () in 11 | words.append(word!) 12 | } 13 | return words 14 | } 15 | 16 | internal func initials() -> String { 17 | let words = self.words() 18 | 19 | var initials = "" 20 | 21 | if (words.count > 0) { 22 | initials += String(words[0][words[0].startIndex]) 23 | } 24 | if (words.count > 1) { 25 | initials += String(words[1][words[1].startIndex]) 26 | } 27 | 28 | return initials 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore/Components/Common/LogoView/LogoView.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | open class LogoView: UIView { 6 | private(set) open var initialsView: InitialsView = InitialsView() 7 | private(set) open var imageView: UIImageView = UIImageView() 8 | 9 | // MARK: Initialization 10 | 11 | override public init(frame: CGRect) { 12 | super.init(frame: frame) 13 | self.setupSubviews() 14 | } 15 | 16 | required public init?(coder aDecoder: NSCoder) { 17 | super.init(coder: aDecoder) 18 | self.setupSubviews() 19 | } 20 | 21 | private func setupSubviews() { 22 | self.imageView.contentMode = UIViewContentMode.scaleAspectFit 23 | self.imageView.clipsToBounds = true 24 | self.initialsView.clipsToBounds = true 25 | self.setupSubview(subview: self.imageView) 26 | self.setupSubview(subview: self.initialsView) 27 | } 28 | 29 | private func setupSubview(subview: UIView) { 30 | self.addSubview(subview) 31 | subview.isHidden = true 32 | } 33 | 34 | open override func layoutSubviews() { 35 | self.imageView.frame = self.bounds 36 | self.initialsView.frame = self.bounds 37 | } 38 | 39 | // MARK: Usage 40 | 41 | open func updateWithTitle(title: String) { 42 | self.initialsView.setInitialsFromTitle(title: title) 43 | self.initialsView.isHidden = false 44 | self.imageView.isHidden = true 45 | } 46 | 47 | open func updateWithImage(image: UIImage?) { 48 | self.imageView.image = image 49 | self.imageView.isHidden = false 50 | self.initialsView.isHidden = true 51 | } 52 | } 53 | -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore/Core/Colors/UIColorMSExtension.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | extension UIColor { 6 | // MARK: Theme Colors 7 | public class func msThemeDarker() -> UIColor { 8 | return UIColor(red:0.000, green:0.271, blue:0.471, alpha:1) // #004578 9 | } 10 | public class func msThemeDark() -> UIColor { 11 | return UIColor(red:0.000, green:0.353, blue:0.620, alpha:1) // #005a9e 12 | } 13 | public class func msThemeDarkAlt() -> UIColor { 14 | return UIColor(red:0.063, green:0.431, blue:0.745, alpha:1) // #106ebe 15 | } 16 | public class func msThemePrimary() -> UIColor { 17 | return UIColor(red:0.000, green:0.471, blue:0.843, alpha:1) // #0078d7 18 | } 19 | public class func msThemeSecondary() -> UIColor { 20 | return UIColor(red:0.169, green:0.533, blue:0.847, alpha:1) // #2b88d8 21 | } 22 | public class func msThemeTertiary() -> UIColor { 23 | return UIColor(red:0.443, green:0.686, blue:0.898, alpha:1) // #71afe5 24 | } 25 | public class func msThemeLight() -> UIColor { 26 | return UIColor(red:0.780, green:0.878, blue:0.957, alpha:1) // #c7e0f4 27 | } 28 | public class func msThemeLighter() -> UIColor { 29 | return UIColor(red:0.871, green:0.925, blue:0.976, alpha:1) // #deecf9 30 | } 31 | public class func msThemeLighterAlt() -> UIColor { 32 | return UIColor(red:0.937, green:0.965, blue:0.988, alpha:1) // #eff6fc 33 | } 34 | 35 | // MARK: Neutral Colors 36 | public class func msNeutralBlack() -> UIColor { 37 | return UIColor(white:0.000, alpha:1) // #000000 38 | } 39 | public class func msNeutralDark() -> UIColor { 40 | return UIColor(white:0.129, alpha:1) // #212121 41 | } 42 | public class func msNeutralPrimary() -> UIColor { 43 | return UIColor(white:0.200, alpha:1) // #333333 44 | } 45 | public class func msNeutralSecondary() -> UIColor { 46 | return UIColor(white:0.400, alpha:1) // #666666 47 | } 48 | public class func msNeutralSecondaryAlt() -> UIColor { 49 | return UIColor(white:0.463, alpha:1) // #767676 50 | } 51 | public class func msNeutralTertiary() -> UIColor { 52 | return UIColor(white:0.651, alpha:1) // #a6a6a6 53 | } 54 | public class func msNeutralTertiaryAlt() -> UIColor { 55 | return UIColor(white:0.784, alpha:1) // #c8c8c8 56 | } 57 | public class func msNeutralLight() -> UIColor { 58 | return UIColor(white:0.918, alpha:1) // #eaeaea 59 | } 60 | public class func msNeutralLighter() -> UIColor { 61 | return UIColor(white:0.957, alpha:1) // #f4f4f4 62 | } 63 | public class func msNeutralLighterAlt() -> UIColor { 64 | return UIColor(white:0.973, alpha:1) // #f8f8f8 65 | } 66 | public class func msNeutralWhite() -> UIColor { 67 | return UIColor(white:1.000, alpha:1) // #ffffff 68 | } 69 | 70 | // MARK: Accent Colors 71 | public class func msAccentYellow() -> UIColor { 72 | return UIColor(red:1.000, green:0.725, blue:0.000, alpha:1) // #ffb900 73 | } 74 | public class func msAccentYellowLight() -> UIColor { 75 | return UIColor(red:1.000, green:0.945, blue:0.000, alpha:1) // #fff100 76 | } 77 | public class func msAccentOrange() -> UIColor { 78 | return UIColor(red:0.847, green:0.231, blue:0.004, alpha:1) // #d83b01 79 | } 80 | public class func msAccentOrangeLight() -> UIColor { 81 | return UIColor(red:1.000, green:0.549, blue:0.000, alpha:1) // #ff8c00 82 | } 83 | public class func msAccentRedDark() -> UIColor { 84 | return UIColor(red:0.659, green:0.000, blue:0.000, alpha:1) // #a80000 85 | } 86 | public class func msAccentRed() -> UIColor { 87 | return UIColor(red:0.910, green:0.067, blue:0.137, alpha:1) // #e81123 88 | } 89 | public class func msAccentMagentaDark() -> UIColor { 90 | return UIColor(red:0.361, green:0.000, blue:0.361, alpha:1) // #5c005c 91 | } 92 | public class func msAccentMagenta() -> UIColor { 93 | return UIColor(red:0.706, green:0.000, blue:0.620, alpha:1) // #b4009e 94 | } 95 | public class func msAccentMagentaLight() -> UIColor { 96 | return UIColor(red:0.890, green:0.000, blue:0.549, alpha:1) // #e3008c 97 | } 98 | public class func msAccentPurpleDark() -> UIColor { 99 | return UIColor(red:0.196, green:0.078, blue:0.353, alpha:1) // #32145a 100 | } 101 | public class func msAccentPurple() -> UIColor { 102 | return UIColor(red:0.361, green:0.176, blue:0.569, alpha:1) // #5c2d91 103 | } 104 | public class func msAccentPurpleLight() -> UIColor { 105 | return UIColor(red:0.706, green:0.627, blue:1.000, alpha:1) // #b4a0ff 106 | } 107 | public class func msAccentBlueDark() -> UIColor { 108 | return UIColor(red:0.000, green:0.125, blue:0.314, alpha:1) // #002050 109 | } 110 | public class func msAccentBlueMid() -> UIColor { 111 | return UIColor(red:0.000, green:0.094, blue:0.561, alpha:1) // #00188f 112 | } 113 | public class func msAccentBlue() -> UIColor { 114 | return UIColor(red:0.000, green:0.471, blue:0.843, alpha:1) // #0078d7 115 | } 116 | public class func msAccentBlueLight() -> UIColor { 117 | return UIColor(red:0.000, green:0.737, blue:0.949, alpha:1) // #00bcf2 118 | } 119 | public class func msAccentTealDark() -> UIColor { 120 | return UIColor(red:0.000, green:0.294, blue:0.314, alpha:1) // #004b50 121 | } 122 | public class func msAccentTeal() -> UIColor { 123 | return UIColor(red:0.000, green:0.510, blue:0.447, alpha:1) // #008272 124 | } 125 | public class func msAccentTealLight() -> UIColor { 126 | return UIColor(red:0.000, green:0.698, blue:0.580, alpha:1) // #00b294 127 | } 128 | public class func msAccentGreenDark() -> UIColor { 129 | return UIColor(red:0.000, green:0.294, blue:0.110, alpha:1) // #004b1c 130 | } 131 | public class func msAccentGreen() -> UIColor { 132 | return UIColor(red:0.063, green:0.486, blue:0.063, alpha:1) // #107c10 133 | } 134 | public class func msAccentGreenLight() -> UIColor { 135 | return UIColor(red:0.729, green:0.847, blue:0.039, alpha:1) // #bad80a 136 | } 137 | } 138 | -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore/Core/Colors/UIColorMSHashExtension.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | extension UIColor { 6 | public class func msHashColor(hash: String) -> UIColor { 7 | var randomNum: UInt64 = 3074457345618258791 8 | 9 | let rgbRed: [CGFloat] = [ 0, 8, 16, 136, 180, 232, 218, 0, 0, 0, 168, 78] 10 | let rgbGreen: [CGFloat] = [120, 130, 124, 23, 0, 17, 59, 111, 94, 78, 0, 37] 11 | let rgbBlue: [CGFloat] = [215, 114, 16, 152, 158, 35, 1, 148, 80, 140, 0, 127] 12 | 13 | for char in hash.characters { 14 | let s = String(char).unicodeScalars 15 | randomNum = randomNum + UInt64(s[s.startIndex].value) 16 | randomNum = randomNum &* 3074457345618258799 17 | } 18 | randomNum = randomNum % UInt64(rgbBlue.count) 19 | let index: Int = Int(randomNum) 20 | return UIColor(red: rgbRed[index] / 255, green: rgbGreen[index] / 255, blue: rgbBlue[index] / 255, alpha: 1) 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore/Core/Typography/MSFontConstants.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | public enum MSFontStyle: String { 6 | case SU = "SU" 7 | case XXL = "XXL" 8 | case XL = "XL" 9 | case L = "L" 10 | case MPlus = "MPlus" 11 | case M = "M" 12 | case SPlus = "SPlus" 13 | case S = "S" 14 | case XS = "XS" 15 | case MI = "MI" 16 | } 17 | 18 | public enum MSFontWeight: String { 19 | case Light = "Thin" 20 | case SemiLight = "Light" 21 | case Regular = "Regular" 22 | case Semibold = "Semibold" 23 | } 24 | 25 | public struct MSFontConstants { 26 | public static func msFontSize(style: MSFontStyle) -> CGFloat { 27 | switch style { 28 | case .SU: return 42 29 | case .XXL: return 28 30 | case .XL: return 21 31 | case .L: return 17 32 | case .MPlus: return 15 33 | case .M: return 14 34 | case .SPlus: return 13 35 | case .S: return 12 36 | case .XS: return 11 37 | case .MI: return 10 38 | } 39 | } 40 | 41 | @available(iOS 8.2, *) 42 | internal static func fontWeight(msFontWeight: MSFontWeight) -> CGFloat { 43 | switch msFontWeight { 44 | case .Light: return UIFontWeightThin 45 | case .SemiLight: return UIFontWeightLight 46 | case .Regular: return UIFontWeightRegular 47 | case .Semibold: return UIFontWeightSemibold 48 | } 49 | } 50 | 51 | public static func msPreferredFontWeight(style: MSFontStyle) -> MSFontWeight { 52 | switch style { 53 | case .SU, .XXL, .XL: 54 | return .Light 55 | case .L: 56 | return .SemiLight 57 | case .MPlus, .M, .SPlus, .S, .XS: 58 | return .Regular 59 | case .MI: 60 | return .Semibold 61 | } 62 | } 63 | } 64 | -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore/Core/Typography/UIFontMSExtension.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | extension UIFont { 6 | public class func msFont(style: MSFontStyle) -> UIFont? { 7 | return msFont(style: style, weight: MSFontConstants.msPreferredFontWeight(style: style)) 8 | } 9 | 10 | public class func msFont(style: MSFontStyle, weight: MSFontWeight) -> UIFont? { 11 | if #available(iOS 8.2, *) { 12 | return self.systemFont(ofSize: MSFontConstants.msFontSize(style: style), weight: MSFontConstants.fontWeight(msFontWeight: weight)) 13 | } 14 | return self.systemFont(ofSize: MSFontConstants.msFontSize(style: style)) 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore/Customization/UIButton/UIButtonMSExtension.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | extension UIButton { 6 | public func msStandardButton(mainColor: UIColor = UIColor.msThemePrimary(), disabledColor: UIColor = UIColor.msNeutralTertiaryAlt()) { 7 | self.setBackgroundImage(UIImage.msButtonBackground(borderColor: mainColor, fillColor: UIColor.clear), for: UIControlState()) 8 | self.setBackgroundImage(UIImage.msButtonBackground(borderColor: mainColor, fillColor: mainColor), for: .highlighted) 9 | self.setBackgroundImage(UIImage.msButtonBackground(borderColor: mainColor, fillColor: mainColor), for: .selected) 10 | self.setBackgroundImage(UIImage.msButtonBackground(borderColor: disabledColor, fillColor: disabledColor.withAlphaComponent(0.1)), for: .disabled) 11 | 12 | self.setTitleColor(mainColor, for: UIControlState()) 13 | self.setTitleColor(UIColor.msNeutralWhite(), for: .highlighted) 14 | self.setTitleColor(UIColor.msNeutralWhite(), for: .selected) 15 | self.setTitleColor(disabledColor, for: .disabled) 16 | } 17 | 18 | public func msPrimaryButton(mainColor: UIColor = UIColor.msThemePrimary(), selectedColor: UIColor = UIColor.msThemeDark(), disabledColor: UIColor = UIColor.msNeutralTertiaryAlt()) { 19 | self.setBackgroundImage(UIImage.msButtonBackground(borderColor: mainColor, fillColor: mainColor), for: UIControlState()) 20 | self.setBackgroundImage(UIImage.msButtonBackground(borderColor: selectedColor, fillColor: selectedColor), for: .highlighted) 21 | self.setBackgroundImage(UIImage.msButtonBackground(borderColor: selectedColor, fillColor: selectedColor), for: .selected) 22 | self.setBackgroundImage(UIImage.msButtonBackground(borderColor: disabledColor, fillColor: disabledColor), for: .disabled) 23 | 24 | self.setTitleColor(UIColor.msNeutralWhite(), for: UIControlState()) 25 | self.setTitleColor(UIColor.msNeutralWhite(), for: .highlighted) 26 | self.setTitleColor(UIColor.msNeutralWhite(), for: .selected) 27 | self.setTitleColor(UIColor.msNeutralWhite(), for: .disabled) 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore/Customization/UIButton/UIImageMSButtonExtension.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | extension UIImage { 6 | class func msButtonBackground(borderColor: UIColor, fillColor: UIColor, scale: CGFloat = UIScreen.main.scale) -> UIImage { 7 | 8 | let strokeWidth: CGFloat = 1 9 | let cornerRadius: CGFloat = 4 10 | let size = 11 * scale 11 | let bounds = CGRect(origin: CGPoint.zero, size: CGSize(width: size, height: size)) 12 | 13 | UIGraphicsBeginImageContextWithOptions(bounds.size, false, scale) 14 | 15 | borderColor.setStroke() 16 | fillColor.setFill() 17 | 18 | let roundedRect = UIBezierPath(roundedRect: bounds, cornerRadius: cornerRadius) 19 | 20 | // Clip corners from dirty pixels 21 | let roundCornerClip = UIBezierPath.reversing(roundedRect)() 22 | roundCornerClip.addClip() 23 | 24 | roundedRect.lineWidth = strokeWidth 25 | roundedRect.fill() 26 | roundedRect.stroke() 27 | 28 | let bgImage = UIGraphicsGetImageFromCurrentImageContext(); 29 | 30 | UIGraphicsEndImageContext() 31 | 32 | return UIImage(cgImage: bgImage!.cgImage!, scale: scale, orientation: UIImageOrientation.up) 33 | .resizableImage( 34 | withCapInsets: UIEdgeInsetsMake( 35 | cornerRadius + strokeWidth, 36 | cornerRadius + strokeWidth, 37 | cornerRadius + strokeWidth, 38 | cornerRadius + strokeWidth 39 | ), resizingMode: UIImageResizingMode.stretch) 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore/Customization/UILabel/UILabelMSExtension.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | extension UILabel { 6 | public func msLabel(style: MSFontStyle = MSFontStyle.L, textColor: UIColor = UIColor.msNeutralPrimary()) { 7 | self.font = UIFont.msFont(style: style, weight: MSFontConstants.msPreferredFontWeight(style: style)) 8 | self.textColor = textColor 9 | } 10 | 11 | public func msLabel(style: MSFontStyle = MSFontStyle.L, fontWeight: MSFontWeight, textColor: UIColor = UIColor.msNeutralPrimary()) { 12 | self.font = UIFont.msFont(style: style, weight: fontWeight) 13 | self.textColor = textColor 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore/Customization/UITextField/UIImageMSTextFieldExtension.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | extension UIImage { 6 | class func msTextFieldBoxBackground(borderColor: UIColor, fillColor: UIColor, scale: CGFloat = UIScreen.main.scale) -> UIImage { 7 | 8 | let innerImageInsets: CGFloat = 1 9 | let strokeWidth: CGFloat = 1 10 | let size = 5 * scale 11 | let bounds = CGRect(origin: CGPoint.zero, size: CGSize(width: size, height: size)) 12 | 13 | UIGraphicsBeginImageContextWithOptions(bounds.size, false, scale) 14 | 15 | borderColor.setStroke() 16 | fillColor.setFill() 17 | 18 | let boxRect = UIBezierPath(rect: bounds) 19 | 20 | boxRect.lineWidth = strokeWidth 21 | boxRect.fill() 22 | boxRect.stroke() 23 | 24 | let bgImage = UIGraphicsGetImageFromCurrentImageContext(); 25 | 26 | UIGraphicsEndImageContext() 27 | 28 | return UIImage(cgImage: bgImage!.cgImage!, scale: scale, orientation: UIImageOrientation.up) 29 | .resizableImage( 30 | withCapInsets: UIEdgeInsetsMake( 31 | innerImageInsets + strokeWidth, 32 | innerImageInsets + strokeWidth, 33 | innerImageInsets + strokeWidth, 34 | innerImageInsets + strokeWidth 35 | ), resizingMode: UIImageResizingMode.stretch) 36 | } 37 | 38 | class func msTextFieldUnderlineBackground(borderColor: UIColor, fillColor: UIColor, scale: CGFloat = UIScreen.main.scale) -> UIImage { 39 | 40 | let innerImageInsets: CGFloat = 1 41 | let strokeWidth: CGFloat = 1 42 | let size = 5 * scale 43 | let bounds = CGRect(origin: CGPoint.zero, size: CGSize(width: size, height: size)) 44 | 45 | UIGraphicsBeginImageContextWithOptions(bounds.size, false, scale) 46 | 47 | borderColor.setStroke() 48 | fillColor.setFill() 49 | 50 | UIBezierPath(rect: bounds).fill() 51 | 52 | let context = UIGraphicsGetCurrentContext() 53 | 54 | context?.move(to: CGPoint(x: 0, y: bounds.height - strokeWidth)) 55 | context?.addLine(to: CGPoint(x: bounds.width, y: bounds.height - strokeWidth)) 56 | 57 | context?.strokePath() 58 | 59 | let bgImage = UIGraphicsGetImageFromCurrentImageContext(); 60 | 61 | UIGraphicsEndImageContext() 62 | 63 | return UIImage(cgImage: bgImage!.cgImage!, scale: scale, orientation: UIImageOrientation.up) 64 | .resizableImage( 65 | withCapInsets: UIEdgeInsetsMake( 66 | innerImageInsets + strokeWidth, 67 | innerImageInsets + strokeWidth, 68 | innerImageInsets + strokeWidth, 69 | innerImageInsets + strokeWidth 70 | ), resizingMode: UIImageResizingMode.stretch) 71 | } 72 | } 73 | -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore/Customization/UITextField/UITextFieldConstants.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | public struct MSTextFieldConstants { 6 | public static let NoPadding: CGFloat = 0 7 | public static let DefaultPadding: CGFloat = 8 8 | } -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore/Customization/UITextField/UITextFieldMSExtension.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | extension UITextField { 6 | 7 | // MARK: TextField Background 8 | 9 | public func msTextFieldBox(borderColor: UIColor = UIColor.msNeutralSecondaryAlt(), backgroundColor: UIColor = UIColor.clear, leftPadding: CGFloat = MSTextFieldConstants.DefaultPadding) { 10 | self.borderStyle = UITextBorderStyle.none 11 | self.background = UIImage.msTextFieldBoxBackground(borderColor: borderColor, fillColor: backgroundColor) 12 | self.setLeftPadding(padding: leftPadding) 13 | } 14 | 15 | public func msTextFieldUnderline(borderColor: UIColor = UIColor.msNeutralSecondaryAlt(), backgroundColor: UIColor = UIColor.clear, leftPadding: CGFloat = MSTextFieldConstants.DefaultPadding) { 16 | self.borderStyle = UITextBorderStyle.none 17 | self.background = UIImage.msTextFieldUnderlineBackground(borderColor: borderColor, fillColor: backgroundColor) 18 | self.setLeftPadding(padding: leftPadding) 19 | } 20 | 21 | private func setLeftPadding(padding: CGFloat) { 22 | let paddingView = UIView(frame: CGRect(x: 0, y: 0, width: padding, height: 0)) 23 | self.leftView = paddingView 24 | self.leftViewMode = UITextFieldViewMode.always 25 | } 26 | 27 | // MARK: TextField Font Style 28 | 29 | public func msTextFieldFontStyles(style: MSFontStyle = MSFontStyle.L, textColor: UIColor = UIColor.msNeutralPrimary()) { 30 | self.msTextFieldFontStyles(style: style, fontWeight: MSFontConstants.msPreferredFontWeight(style: style), textColor: textColor) 31 | } 32 | 33 | public func msTextFieldFontStyles(style: MSFontStyle = MSFontStyle.L, fontWeight: MSFontWeight, textColor: UIColor = UIColor.msNeutralPrimary()) { 34 | self.msTextFieldFontStyles(font: UIFont.msFont(style: style, weight: fontWeight), textColor: textColor) 35 | } 36 | 37 | public func msTextFieldFontStyles(font: UIFont?, textColor: UIColor = UIColor.msNeutralPrimary()) { 38 | self.font = font 39 | self.textColor = textColor 40 | } 41 | 42 | // MARK: TextField Placeholder Text 43 | 44 | public func msTextFieldPlaceholderText(text: String, placeholderColor: UIColor = UIColor.msNeutralSecondary(), font: UIFont? = nil) { 45 | if let font = font { 46 | self.attributedPlaceholder = NSAttributedString(string: text, attributes: [ 47 | NSForegroundColorAttributeName: placeholderColor, 48 | NSFontAttributeName: font 49 | ]); 50 | } else { 51 | self.attributedPlaceholder = NSAttributedString(string: text, attributes: [ 52 | NSForegroundColorAttributeName: placeholderColor 53 | ]); 54 | } 55 | } 56 | 57 | // MARK: Permament Placeholder Text 58 | 59 | public func msTextFieldPermanentPlaceholderText(text: String, placeholderColor: UIColor = UIColor.msNeutralSecondary(), font: UIFont? = nil, padding: CGFloat = MSTextFieldConstants.DefaultPadding * 2) { 60 | let placeholderLabel = UILabel() 61 | if let font = font ?? self.font { 62 | placeholderLabel.font = font 63 | } 64 | placeholderLabel.textColor = placeholderColor 65 | placeholderLabel.text = text 66 | placeholderLabel.sizeToFit() 67 | placeholderLabel.textAlignment = .center 68 | placeholderLabel.frame = CGRect( 69 | origin: placeholderLabel.frame.origin, 70 | size: CGSize(width: placeholderLabel.frame.width + padding, height: self.frame.size.height) 71 | ) 72 | self.leftView = placeholderLabel 73 | self.leftViewMode = UITextFieldViewMode.always 74 | } 75 | } 76 | -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 0.2.1 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | $(CURRENT_PROJECT_VERSION) 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /OfficeUIFabricCore/OfficeUIFabricCore/OfficeUIFabricCore.h: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | #import 4 | 5 | //! Project version number for OfficeUIFabricCore. 6 | FOUNDATION_EXPORT double OfficeUIFabricCoreVersionNumber; 7 | 8 | //! Project version string for OfficeUIFabricCore. 9 | FOUNDATION_EXPORT const unsigned char OfficeUIFabricCoreVersionString[]; 10 | 11 | // In this header, you should import all the public headers of your framework using statements like #import 12 | 13 | 14 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | A63554A81CA5E88C00B33AF2 /* LabelDemoViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = A63554A71CA5E88C00B33AF2 /* LabelDemoViewController.swift */; }; 11 | A63554AA1CA9A1D300B33AF2 /* TextFieldDemoViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = A63554A91CA9A1D300B33AF2 /* TextFieldDemoViewController.swift */; }; 12 | A6371FB01C6279AE0086CB29 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = A6371FAF1C6279AE0086CB29 /* AppDelegate.swift */; }; 13 | A6371FB51C6279AE0086CB29 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = A6371FB31C6279AE0086CB29 /* Main.storyboard */; }; 14 | A6371FB71C6279AE0086CB29 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = A6371FB61C6279AE0086CB29 /* Assets.xcassets */; }; 15 | A6371FBA1C6279AE0086CB29 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = A6371FB81C6279AE0086CB29 /* LaunchScreen.storyboard */; }; 16 | A6371FD31C627AB80086CB29 /* ColorItemCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = A6371FC41C627AB80086CB29 /* ColorItemCell.swift */; }; 17 | A6371FD41C627AB80086CB29 /* ColorPaletteTableViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = A6371FC51C627AB80086CB29 /* ColorPaletteTableViewController.swift */; }; 18 | A6371FD51C627AB80086CB29 /* ColorsDataSource.swift in Sources */ = {isa = PBXBuildFile; fileRef = A6371FC61C627AB80086CB29 /* ColorsDataSource.swift */; }; 19 | A6371FD61C627AB80086CB29 /* ColorsSectionHeader.swift in Sources */ = {isa = PBXBuildFile; fileRef = A6371FC71C627AB80086CB29 /* ColorsSectionHeader.swift */; }; 20 | A6371FD71C627AB80086CB29 /* ColorsSectionHeader.xib in Resources */ = {isa = PBXBuildFile; fileRef = A6371FC81C627AB80086CB29 /* ColorsSectionHeader.xib */; }; 21 | A6371FD81C627AB80086CB29 /* FontItemCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = A6371FCA1C627AB80086CB29 /* FontItemCell.swift */; }; 22 | A6371FD91C627AB80086CB29 /* FontsTableViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = A6371FCB1C627AB80086CB29 /* FontsTableViewController.swift */; }; 23 | A6371FDB1C627AB80086CB29 /* DemoItemCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = A6371FCF1C627AB80086CB29 /* DemoItemCell.swift */; }; 24 | A6371FDC1C627AB80086CB29 /* DemoSectionHeader.swift in Sources */ = {isa = PBXBuildFile; fileRef = A6371FD01C627AB80086CB29 /* DemoSectionHeader.swift */; }; 25 | A6371FDD1C627AB80086CB29 /* DemoSectionHeader.xib in Resources */ = {isa = PBXBuildFile; fileRef = A6371FD11C627AB80086CB29 /* DemoSectionHeader.xib */; }; 26 | A6371FDE1C627AB80086CB29 /* MainTableViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = A6371FD21C627AB80086CB29 /* MainTableViewController.swift */; }; 27 | A64292851C87BBC300BE008F /* LogoViewItemCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = A64292841C87BBC300BE008F /* LogoViewItemCell.swift */; }; 28 | A657A4D61C8799F7007B2414 /* InitialsView.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = A657A4D51C8799F7007B2414 /* InitialsView.storyboard */; }; 29 | A657A4D81C879B73007B2414 /* InitialsViewTableViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = A657A4D71C879B73007B2414 /* InitialsViewTableViewController.swift */; }; 30 | A657A4DA1C879BF0007B2414 /* InitialsViewItemCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = A657A4D91C879BF0007B2414 /* InitialsViewItemCell.swift */; }; 31 | A657A4E31C87B9EE007B2414 /* LogoViewTableViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = A657A4E21C87B9EE007B2414 /* LogoViewTableViewController.swift */; }; 32 | A657A4E51C87B9FF007B2414 /* LogoView.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = A657A4E41C87B9FF007B2414 /* LogoView.storyboard */; }; 33 | A68B15751C63C59400AAAFC6 /* OfficeUIFabricCore.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = A6574FFE1C62ABC30046CD63 /* OfficeUIFabricCore.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 34 | A6AEDB311C8F7B89000A62E8 /* ButtonDemoViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = A6AEDB301C8F7B89000A62E8 /* ButtonDemoViewController.swift */; }; 35 | /* End PBXBuildFile section */ 36 | 37 | /* Begin PBXContainerItemProxy section */ 38 | A6574FFD1C62ABC30046CD63 /* PBXContainerItemProxy */ = { 39 | isa = PBXContainerItemProxy; 40 | containerPortal = A6574FF91C62ABC30046CD63 /* OfficeUIFabricCore.xcodeproj */; 41 | proxyType = 2; 42 | remoteGlobalIDString = A6371F881C6272560086CB29; 43 | remoteInfo = OfficeUIFabricCore; 44 | }; 45 | A6574FFF1C62ABD40046CD63 /* PBXContainerItemProxy */ = { 46 | isa = PBXContainerItemProxy; 47 | containerPortal = A6574FF91C62ABC30046CD63 /* OfficeUIFabricCore.xcodeproj */; 48 | proxyType = 1; 49 | remoteGlobalIDString = A6371F871C6272560086CB29; 50 | remoteInfo = OfficeUIFabricCore; 51 | }; 52 | A68B15761C63C59400AAAFC6 /* PBXContainerItemProxy */ = { 53 | isa = PBXContainerItemProxy; 54 | containerPortal = A6574FF91C62ABC30046CD63 /* OfficeUIFabricCore.xcodeproj */; 55 | proxyType = 1; 56 | remoteGlobalIDString = A6371F871C6272560086CB29; 57 | remoteInfo = OfficeUIFabricCore; 58 | }; 59 | /* End PBXContainerItemProxy section */ 60 | 61 | /* Begin PBXCopyFilesBuildPhase section */ 62 | A68B15781C63C59500AAAFC6 /* Embed Frameworks */ = { 63 | isa = PBXCopyFilesBuildPhase; 64 | buildActionMask = 2147483647; 65 | dstPath = ""; 66 | dstSubfolderSpec = 10; 67 | files = ( 68 | A68B15751C63C59400AAAFC6 /* OfficeUIFabricCore.framework in Embed Frameworks */, 69 | ); 70 | name = "Embed Frameworks"; 71 | runOnlyForDeploymentPostprocessing = 0; 72 | }; 73 | /* End PBXCopyFilesBuildPhase section */ 74 | 75 | /* Begin PBXFileReference section */ 76 | A63554A71CA5E88C00B33AF2 /* LabelDemoViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = LabelDemoViewController.swift; sourceTree = ""; }; 77 | A63554A91CA9A1D300B33AF2 /* TextFieldDemoViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TextFieldDemoViewController.swift; sourceTree = ""; }; 78 | A6371FAC1C6279AE0086CB29 /* OfficeUIFabricDemo.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = OfficeUIFabricDemo.app; sourceTree = BUILT_PRODUCTS_DIR; }; 79 | A6371FAF1C6279AE0086CB29 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; 80 | A6371FB41C6279AE0086CB29 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 81 | A6371FB61C6279AE0086CB29 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 82 | A6371FB91C6279AE0086CB29 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 83 | A6371FBB1C6279AE0086CB29 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 84 | A6371FC41C627AB80086CB29 /* ColorItemCell.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ColorItemCell.swift; sourceTree = ""; }; 85 | A6371FC51C627AB80086CB29 /* ColorPaletteTableViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ColorPaletteTableViewController.swift; sourceTree = ""; }; 86 | A6371FC61C627AB80086CB29 /* ColorsDataSource.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ColorsDataSource.swift; sourceTree = ""; }; 87 | A6371FC71C627AB80086CB29 /* ColorsSectionHeader.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ColorsSectionHeader.swift; sourceTree = ""; }; 88 | A6371FC81C627AB80086CB29 /* ColorsSectionHeader.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = ColorsSectionHeader.xib; sourceTree = ""; }; 89 | A6371FCA1C627AB80086CB29 /* FontItemCell.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = FontItemCell.swift; sourceTree = ""; }; 90 | A6371FCB1C627AB80086CB29 /* FontsTableViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = FontsTableViewController.swift; sourceTree = ""; }; 91 | A6371FCF1C627AB80086CB29 /* DemoItemCell.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = DemoItemCell.swift; sourceTree = ""; }; 92 | A6371FD01C627AB80086CB29 /* DemoSectionHeader.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = DemoSectionHeader.swift; sourceTree = ""; }; 93 | A6371FD11C627AB80086CB29 /* DemoSectionHeader.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = DemoSectionHeader.xib; sourceTree = ""; }; 94 | A6371FD21C627AB80086CB29 /* MainTableViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = MainTableViewController.swift; sourceTree = ""; }; 95 | A64292841C87BBC300BE008F /* LogoViewItemCell.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = LogoViewItemCell.swift; sourceTree = ""; }; 96 | A6574FF91C62ABC30046CD63 /* OfficeUIFabricCore.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = OfficeUIFabricCore.xcodeproj; path = ../OfficeUIFabricCore/OfficeUIFabricCore.xcodeproj; sourceTree = ""; }; 97 | A657A4D51C8799F7007B2414 /* InitialsView.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = InitialsView.storyboard; sourceTree = ""; }; 98 | A657A4D71C879B73007B2414 /* InitialsViewTableViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = InitialsViewTableViewController.swift; sourceTree = ""; }; 99 | A657A4D91C879BF0007B2414 /* InitialsViewItemCell.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = InitialsViewItemCell.swift; sourceTree = ""; }; 100 | A657A4E21C87B9EE007B2414 /* LogoViewTableViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = LogoViewTableViewController.swift; sourceTree = ""; }; 101 | A657A4E41C87B9FF007B2414 /* LogoView.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = LogoView.storyboard; sourceTree = ""; }; 102 | A6AEDB301C8F7B89000A62E8 /* ButtonDemoViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ButtonDemoViewController.swift; sourceTree = ""; }; 103 | /* End PBXFileReference section */ 104 | 105 | /* Begin PBXFrameworksBuildPhase section */ 106 | A6371FA91C6279AE0086CB29 /* Frameworks */ = { 107 | isa = PBXFrameworksBuildPhase; 108 | buildActionMask = 2147483647; 109 | files = ( 110 | ); 111 | runOnlyForDeploymentPostprocessing = 0; 112 | }; 113 | /* End PBXFrameworksBuildPhase section */ 114 | 115 | /* Begin PBXGroup section */ 116 | A6371FA31C6279AE0086CB29 = { 117 | isa = PBXGroup; 118 | children = ( 119 | A6371FAE1C6279AE0086CB29 /* OfficeUIFabricDemo */, 120 | A6371FAD1C6279AE0086CB29 /* Products */, 121 | A6574FF91C62ABC30046CD63 /* OfficeUIFabricCore.xcodeproj */, 122 | ); 123 | sourceTree = ""; 124 | }; 125 | A6371FAD1C6279AE0086CB29 /* Products */ = { 126 | isa = PBXGroup; 127 | children = ( 128 | A6371FAC1C6279AE0086CB29 /* OfficeUIFabricDemo.app */, 129 | ); 130 | name = Products; 131 | sourceTree = ""; 132 | }; 133 | A6371FAE1C6279AE0086CB29 /* OfficeUIFabricDemo */ = { 134 | isa = PBXGroup; 135 | children = ( 136 | A6371FC21C627AB80086CB29 /* DemoControllers */, 137 | A6371FAF1C6279AE0086CB29 /* AppDelegate.swift */, 138 | A6371FC11C627A580086CB29 /* SupportingFiles */, 139 | ); 140 | path = OfficeUIFabricDemo; 141 | sourceTree = ""; 142 | }; 143 | A6371FC11C627A580086CB29 /* SupportingFiles */ = { 144 | isa = PBXGroup; 145 | children = ( 146 | A6371FB31C6279AE0086CB29 /* Main.storyboard */, 147 | A6371FB61C6279AE0086CB29 /* Assets.xcassets */, 148 | A6371FB81C6279AE0086CB29 /* LaunchScreen.storyboard */, 149 | A6371FBB1C6279AE0086CB29 /* Info.plist */, 150 | ); 151 | name = SupportingFiles; 152 | sourceTree = ""; 153 | }; 154 | A6371FC21C627AB80086CB29 /* DemoControllers */ = { 155 | isa = PBXGroup; 156 | children = ( 157 | A657A4D31C8799CA007B2414 /* Components */, 158 | A6AEDB2F1C8F7B6F000A62E8 /* Customization */, 159 | A6371FC31C627AB80086CB29 /* Colors */, 160 | A6371FC91C627AB80086CB29 /* Fonts */, 161 | A6371FCE1C627AB80086CB29 /* Main */, 162 | ); 163 | path = DemoControllers; 164 | sourceTree = ""; 165 | }; 166 | A6371FC31C627AB80086CB29 /* Colors */ = { 167 | isa = PBXGroup; 168 | children = ( 169 | A6371FC41C627AB80086CB29 /* ColorItemCell.swift */, 170 | A6371FC51C627AB80086CB29 /* ColorPaletteTableViewController.swift */, 171 | A6371FC61C627AB80086CB29 /* ColorsDataSource.swift */, 172 | A6371FC71C627AB80086CB29 /* ColorsSectionHeader.swift */, 173 | A6371FC81C627AB80086CB29 /* ColorsSectionHeader.xib */, 174 | ); 175 | path = Colors; 176 | sourceTree = ""; 177 | }; 178 | A6371FC91C627AB80086CB29 /* Fonts */ = { 179 | isa = PBXGroup; 180 | children = ( 181 | A6371FCA1C627AB80086CB29 /* FontItemCell.swift */, 182 | A6371FCB1C627AB80086CB29 /* FontsTableViewController.swift */, 183 | ); 184 | path = Fonts; 185 | sourceTree = ""; 186 | }; 187 | A6371FCE1C627AB80086CB29 /* Main */ = { 188 | isa = PBXGroup; 189 | children = ( 190 | A6371FCF1C627AB80086CB29 /* DemoItemCell.swift */, 191 | A6371FD01C627AB80086CB29 /* DemoSectionHeader.swift */, 192 | A6371FD11C627AB80086CB29 /* DemoSectionHeader.xib */, 193 | A6371FD21C627AB80086CB29 /* MainTableViewController.swift */, 194 | ); 195 | path = Main; 196 | sourceTree = ""; 197 | }; 198 | A6574FFA1C62ABC30046CD63 /* Products */ = { 199 | isa = PBXGroup; 200 | children = ( 201 | A6574FFE1C62ABC30046CD63 /* OfficeUIFabricCore.framework */, 202 | ); 203 | name = Products; 204 | sourceTree = ""; 205 | }; 206 | A657A4D31C8799CA007B2414 /* Components */ = { 207 | isa = PBXGroup; 208 | children = ( 209 | A657A4D41C8799CA007B2414 /* InitialsView */, 210 | A657A4E11C87B9D6007B2414 /* LogoView */, 211 | ); 212 | path = Components; 213 | sourceTree = ""; 214 | }; 215 | A657A4D41C8799CA007B2414 /* InitialsView */ = { 216 | isa = PBXGroup; 217 | children = ( 218 | A657A4D51C8799F7007B2414 /* InitialsView.storyboard */, 219 | A657A4D71C879B73007B2414 /* InitialsViewTableViewController.swift */, 220 | A657A4D91C879BF0007B2414 /* InitialsViewItemCell.swift */, 221 | ); 222 | path = InitialsView; 223 | sourceTree = ""; 224 | }; 225 | A657A4E11C87B9D6007B2414 /* LogoView */ = { 226 | isa = PBXGroup; 227 | children = ( 228 | A657A4E41C87B9FF007B2414 /* LogoView.storyboard */, 229 | A657A4E21C87B9EE007B2414 /* LogoViewTableViewController.swift */, 230 | A64292841C87BBC300BE008F /* LogoViewItemCell.swift */, 231 | ); 232 | path = LogoView; 233 | sourceTree = ""; 234 | }; 235 | A6AEDB2F1C8F7B6F000A62E8 /* Customization */ = { 236 | isa = PBXGroup; 237 | children = ( 238 | A6AEDB301C8F7B89000A62E8 /* ButtonDemoViewController.swift */, 239 | A63554A71CA5E88C00B33AF2 /* LabelDemoViewController.swift */, 240 | A63554A91CA9A1D300B33AF2 /* TextFieldDemoViewController.swift */, 241 | ); 242 | path = Customization; 243 | sourceTree = ""; 244 | }; 245 | /* End PBXGroup section */ 246 | 247 | /* Begin PBXNativeTarget section */ 248 | A6371FAB1C6279AE0086CB29 /* OfficeUIFabricDemo */ = { 249 | isa = PBXNativeTarget; 250 | buildConfigurationList = A6371FBE1C6279AE0086CB29 /* Build configuration list for PBXNativeTarget "OfficeUIFabricDemo" */; 251 | buildPhases = ( 252 | A6371FA81C6279AE0086CB29 /* Sources */, 253 | A6371FA91C6279AE0086CB29 /* Frameworks */, 254 | A6371FAA1C6279AE0086CB29 /* Resources */, 255 | A68B15781C63C59500AAAFC6 /* Embed Frameworks */, 256 | ); 257 | buildRules = ( 258 | ); 259 | dependencies = ( 260 | A65750001C62ABD40046CD63 /* PBXTargetDependency */, 261 | A68B15771C63C59400AAAFC6 /* PBXTargetDependency */, 262 | ); 263 | name = OfficeUIFabricDemo; 264 | productName = OfficeUIFabricDemo; 265 | productReference = A6371FAC1C6279AE0086CB29 /* OfficeUIFabricDemo.app */; 266 | productType = "com.apple.product-type.application"; 267 | }; 268 | /* End PBXNativeTarget section */ 269 | 270 | /* Begin PBXProject section */ 271 | A6371FA41C6279AE0086CB29 /* Project object */ = { 272 | isa = PBXProject; 273 | attributes = { 274 | LastSwiftUpdateCheck = 0720; 275 | LastUpgradeCheck = 0800; 276 | ORGANIZATIONNAME = Microsoft; 277 | TargetAttributes = { 278 | A6371FAB1C6279AE0086CB29 = { 279 | CreatedOnToolsVersion = 7.2; 280 | LastSwiftMigration = 0800; 281 | }; 282 | }; 283 | }; 284 | buildConfigurationList = A6371FA71C6279AE0086CB29 /* Build configuration list for PBXProject "OfficeUIFabricDemo" */; 285 | compatibilityVersion = "Xcode 3.2"; 286 | developmentRegion = English; 287 | hasScannedForEncodings = 0; 288 | knownRegions = ( 289 | en, 290 | Base, 291 | ); 292 | mainGroup = A6371FA31C6279AE0086CB29; 293 | productRefGroup = A6371FAD1C6279AE0086CB29 /* Products */; 294 | projectDirPath = ""; 295 | projectReferences = ( 296 | { 297 | ProductGroup = A6574FFA1C62ABC30046CD63 /* Products */; 298 | ProjectRef = A6574FF91C62ABC30046CD63 /* OfficeUIFabricCore.xcodeproj */; 299 | }, 300 | ); 301 | projectRoot = ""; 302 | targets = ( 303 | A6371FAB1C6279AE0086CB29 /* OfficeUIFabricDemo */, 304 | ); 305 | }; 306 | /* End PBXProject section */ 307 | 308 | /* Begin PBXReferenceProxy section */ 309 | A6574FFE1C62ABC30046CD63 /* OfficeUIFabricCore.framework */ = { 310 | isa = PBXReferenceProxy; 311 | fileType = wrapper.framework; 312 | path = OfficeUIFabricCore.framework; 313 | remoteRef = A6574FFD1C62ABC30046CD63 /* PBXContainerItemProxy */; 314 | sourceTree = BUILT_PRODUCTS_DIR; 315 | }; 316 | /* End PBXReferenceProxy section */ 317 | 318 | /* Begin PBXResourcesBuildPhase section */ 319 | A6371FAA1C6279AE0086CB29 /* Resources */ = { 320 | isa = PBXResourcesBuildPhase; 321 | buildActionMask = 2147483647; 322 | files = ( 323 | A6371FD71C627AB80086CB29 /* ColorsSectionHeader.xib in Resources */, 324 | A6371FBA1C6279AE0086CB29 /* LaunchScreen.storyboard in Resources */, 325 | A657A4D61C8799F7007B2414 /* InitialsView.storyboard in Resources */, 326 | A6371FB71C6279AE0086CB29 /* Assets.xcassets in Resources */, 327 | A657A4E51C87B9FF007B2414 /* LogoView.storyboard in Resources */, 328 | A6371FB51C6279AE0086CB29 /* Main.storyboard in Resources */, 329 | A6371FDD1C627AB80086CB29 /* DemoSectionHeader.xib in Resources */, 330 | ); 331 | runOnlyForDeploymentPostprocessing = 0; 332 | }; 333 | /* End PBXResourcesBuildPhase section */ 334 | 335 | /* Begin PBXSourcesBuildPhase section */ 336 | A6371FA81C6279AE0086CB29 /* Sources */ = { 337 | isa = PBXSourcesBuildPhase; 338 | buildActionMask = 2147483647; 339 | files = ( 340 | A6371FDE1C627AB80086CB29 /* MainTableViewController.swift in Sources */, 341 | A6371FD61C627AB80086CB29 /* ColorsSectionHeader.swift in Sources */, 342 | A6371FD81C627AB80086CB29 /* FontItemCell.swift in Sources */, 343 | A6371FD31C627AB80086CB29 /* ColorItemCell.swift in Sources */, 344 | A64292851C87BBC300BE008F /* LogoViewItemCell.swift in Sources */, 345 | A6AEDB311C8F7B89000A62E8 /* ButtonDemoViewController.swift in Sources */, 346 | A657A4DA1C879BF0007B2414 /* InitialsViewItemCell.swift in Sources */, 347 | A657A4E31C87B9EE007B2414 /* LogoViewTableViewController.swift in Sources */, 348 | A6371FB01C6279AE0086CB29 /* AppDelegate.swift in Sources */, 349 | A6371FD51C627AB80086CB29 /* ColorsDataSource.swift in Sources */, 350 | A6371FD41C627AB80086CB29 /* ColorPaletteTableViewController.swift in Sources */, 351 | A6371FD91C627AB80086CB29 /* FontsTableViewController.swift in Sources */, 352 | A63554AA1CA9A1D300B33AF2 /* TextFieldDemoViewController.swift in Sources */, 353 | A63554A81CA5E88C00B33AF2 /* LabelDemoViewController.swift in Sources */, 354 | A6371FDC1C627AB80086CB29 /* DemoSectionHeader.swift in Sources */, 355 | A6371FDB1C627AB80086CB29 /* DemoItemCell.swift in Sources */, 356 | A657A4D81C879B73007B2414 /* InitialsViewTableViewController.swift in Sources */, 357 | ); 358 | runOnlyForDeploymentPostprocessing = 0; 359 | }; 360 | /* End PBXSourcesBuildPhase section */ 361 | 362 | /* Begin PBXTargetDependency section */ 363 | A65750001C62ABD40046CD63 /* PBXTargetDependency */ = { 364 | isa = PBXTargetDependency; 365 | name = OfficeUIFabricCore; 366 | targetProxy = A6574FFF1C62ABD40046CD63 /* PBXContainerItemProxy */; 367 | }; 368 | A68B15771C63C59400AAAFC6 /* PBXTargetDependency */ = { 369 | isa = PBXTargetDependency; 370 | name = OfficeUIFabricCore; 371 | targetProxy = A68B15761C63C59400AAAFC6 /* PBXContainerItemProxy */; 372 | }; 373 | /* End PBXTargetDependency section */ 374 | 375 | /* Begin PBXVariantGroup section */ 376 | A6371FB31C6279AE0086CB29 /* Main.storyboard */ = { 377 | isa = PBXVariantGroup; 378 | children = ( 379 | A6371FB41C6279AE0086CB29 /* Base */, 380 | ); 381 | name = Main.storyboard; 382 | sourceTree = ""; 383 | }; 384 | A6371FB81C6279AE0086CB29 /* LaunchScreen.storyboard */ = { 385 | isa = PBXVariantGroup; 386 | children = ( 387 | A6371FB91C6279AE0086CB29 /* Base */, 388 | ); 389 | name = LaunchScreen.storyboard; 390 | sourceTree = ""; 391 | }; 392 | /* End PBXVariantGroup section */ 393 | 394 | /* Begin XCBuildConfiguration section */ 395 | A6371FBC1C6279AE0086CB29 /* Debug */ = { 396 | isa = XCBuildConfiguration; 397 | buildSettings = { 398 | ALWAYS_SEARCH_USER_PATHS = NO; 399 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 400 | CLANG_CXX_LIBRARY = "libc++"; 401 | CLANG_ENABLE_MODULES = YES; 402 | CLANG_ENABLE_OBJC_ARC = YES; 403 | CLANG_WARN_BOOL_CONVERSION = YES; 404 | CLANG_WARN_CONSTANT_CONVERSION = YES; 405 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 406 | CLANG_WARN_EMPTY_BODY = YES; 407 | CLANG_WARN_ENUM_CONVERSION = YES; 408 | CLANG_WARN_INFINITE_RECURSION = YES; 409 | CLANG_WARN_INT_CONVERSION = YES; 410 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 411 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 412 | CLANG_WARN_UNREACHABLE_CODE = YES; 413 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 414 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 415 | COPY_PHASE_STRIP = NO; 416 | DEBUG_INFORMATION_FORMAT = dwarf; 417 | ENABLE_STRICT_OBJC_MSGSEND = YES; 418 | ENABLE_TESTABILITY = YES; 419 | GCC_C_LANGUAGE_STANDARD = gnu99; 420 | GCC_DYNAMIC_NO_PIC = NO; 421 | GCC_NO_COMMON_BLOCKS = YES; 422 | GCC_OPTIMIZATION_LEVEL = 0; 423 | GCC_PREPROCESSOR_DEFINITIONS = ( 424 | "DEBUG=1", 425 | "$(inherited)", 426 | ); 427 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 428 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 429 | GCC_WARN_UNDECLARED_SELECTOR = YES; 430 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 431 | GCC_WARN_UNUSED_FUNCTION = YES; 432 | GCC_WARN_UNUSED_VARIABLE = YES; 433 | IPHONEOS_DEPLOYMENT_TARGET = 9.2; 434 | MTL_ENABLE_DEBUG_INFO = YES; 435 | ONLY_ACTIVE_ARCH = YES; 436 | SDKROOT = iphoneos; 437 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 438 | TARGETED_DEVICE_FAMILY = "1,2"; 439 | }; 440 | name = Debug; 441 | }; 442 | A6371FBD1C6279AE0086CB29 /* Release */ = { 443 | isa = XCBuildConfiguration; 444 | buildSettings = { 445 | ALWAYS_SEARCH_USER_PATHS = NO; 446 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 447 | CLANG_CXX_LIBRARY = "libc++"; 448 | CLANG_ENABLE_MODULES = YES; 449 | CLANG_ENABLE_OBJC_ARC = YES; 450 | CLANG_WARN_BOOL_CONVERSION = YES; 451 | CLANG_WARN_CONSTANT_CONVERSION = YES; 452 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 453 | CLANG_WARN_EMPTY_BODY = YES; 454 | CLANG_WARN_ENUM_CONVERSION = YES; 455 | CLANG_WARN_INFINITE_RECURSION = YES; 456 | CLANG_WARN_INT_CONVERSION = YES; 457 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 458 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 459 | CLANG_WARN_UNREACHABLE_CODE = YES; 460 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 461 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 462 | COPY_PHASE_STRIP = NO; 463 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 464 | ENABLE_NS_ASSERTIONS = NO; 465 | ENABLE_STRICT_OBJC_MSGSEND = YES; 466 | GCC_C_LANGUAGE_STANDARD = gnu99; 467 | GCC_NO_COMMON_BLOCKS = YES; 468 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 469 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 470 | GCC_WARN_UNDECLARED_SELECTOR = YES; 471 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 472 | GCC_WARN_UNUSED_FUNCTION = YES; 473 | GCC_WARN_UNUSED_VARIABLE = YES; 474 | IPHONEOS_DEPLOYMENT_TARGET = 9.2; 475 | MTL_ENABLE_DEBUG_INFO = NO; 476 | SDKROOT = iphoneos; 477 | SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; 478 | TARGETED_DEVICE_FAMILY = "1,2"; 479 | VALIDATE_PRODUCT = YES; 480 | }; 481 | name = Release; 482 | }; 483 | A6371FBF1C6279AE0086CB29 /* Debug */ = { 484 | isa = XCBuildConfiguration; 485 | buildSettings = { 486 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; 487 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 488 | INFOPLIST_FILE = OfficeUIFabricDemo/Info.plist; 489 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 490 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 491 | PRODUCT_BUNDLE_IDENTIFIER = "com.officeui-fabric.OfficeUIFabricDemo"; 492 | PRODUCT_NAME = "$(TARGET_NAME)"; 493 | SWIFT_VERSION = 3.0; 494 | }; 495 | name = Debug; 496 | }; 497 | A6371FC01C6279AE0086CB29 /* Release */ = { 498 | isa = XCBuildConfiguration; 499 | buildSettings = { 500 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; 501 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 502 | INFOPLIST_FILE = OfficeUIFabricDemo/Info.plist; 503 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 504 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 505 | PRODUCT_BUNDLE_IDENTIFIER = "com.officeui-fabric.OfficeUIFabricDemo"; 506 | PRODUCT_NAME = "$(TARGET_NAME)"; 507 | SWIFT_VERSION = 3.0; 508 | }; 509 | name = Release; 510 | }; 511 | /* End XCBuildConfiguration section */ 512 | 513 | /* Begin XCConfigurationList section */ 514 | A6371FA71C6279AE0086CB29 /* Build configuration list for PBXProject "OfficeUIFabricDemo" */ = { 515 | isa = XCConfigurationList; 516 | buildConfigurations = ( 517 | A6371FBC1C6279AE0086CB29 /* Debug */, 518 | A6371FBD1C6279AE0086CB29 /* Release */, 519 | ); 520 | defaultConfigurationIsVisible = 0; 521 | defaultConfigurationName = Release; 522 | }; 523 | A6371FBE1C6279AE0086CB29 /* Build configuration list for PBXNativeTarget "OfficeUIFabricDemo" */ = { 524 | isa = XCConfigurationList; 525 | buildConfigurations = ( 526 | A6371FBF1C6279AE0086CB29 /* Debug */, 527 | A6371FC01C6279AE0086CB29 /* Release */, 528 | ); 529 | defaultConfigurationIsVisible = 0; 530 | defaultConfigurationName = Release; 531 | }; 532 | /* End XCConfigurationList section */ 533 | }; 534 | rootObject = A6371FA41C6279AE0086CB29 /* Project object */; 535 | } 536 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | @UIApplicationMain 6 | class AppDelegate: UIResponder, UIApplicationDelegate { 7 | 8 | var window: UIWindow? 9 | 10 | func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { 11 | return true 12 | } 13 | 14 | func applicationWillResignActive(_ application: UIApplication) { } 15 | 16 | func applicationDidEnterBackground(_ application: UIApplication) { } 17 | 18 | func applicationWillEnterForeground(_ application: UIApplication) { } 19 | 20 | func applicationDidBecomeActive(_ application: UIApplication) { } 21 | 22 | func applicationWillTerminate(_ application: UIApplication) { } 23 | 24 | } 25 | 26 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "size" : "29x29", 5 | "idiom" : "iphone", 6 | "filename" : "OfficeUIFabric29@2x.png", 7 | "scale" : "2x" 8 | }, 9 | { 10 | "size" : "29x29", 11 | "idiom" : "iphone", 12 | "filename" : "OfficeUIFabric29@3x.png", 13 | "scale" : "3x" 14 | }, 15 | { 16 | "size" : "40x40", 17 | "idiom" : "iphone", 18 | "filename" : "OfficeUIFabric40@2x.png", 19 | "scale" : "2x" 20 | }, 21 | { 22 | "size" : "40x40", 23 | "idiom" : "iphone", 24 | "filename" : "OfficeUIFabric40@3x.png", 25 | "scale" : "3x" 26 | }, 27 | { 28 | "size" : "60x60", 29 | "idiom" : "iphone", 30 | "filename" : "OfficeUIFabric60@2x.png", 31 | "scale" : "2x" 32 | }, 33 | { 34 | "size" : "60x60", 35 | "idiom" : "iphone", 36 | "filename" : "OfficeUIFabric60@3x.png", 37 | "scale" : "3x" 38 | }, 39 | { 40 | "size" : "29x29", 41 | "idiom" : "ipad", 42 | "filename" : "OfficeUIFabric29.png", 43 | "scale" : "1x" 44 | }, 45 | { 46 | "size" : "29x29", 47 | "idiom" : "ipad", 48 | "filename" : "OfficeUIFabric29@2x-1.png", 49 | "scale" : "2x" 50 | }, 51 | { 52 | "size" : "40x40", 53 | "idiom" : "ipad", 54 | "filename" : "OfficeUIFabric40.png", 55 | "scale" : "1x" 56 | }, 57 | { 58 | "size" : "40x40", 59 | "idiom" : "ipad", 60 | "filename" : "OfficeUIFabric40@2x-1.png", 61 | "scale" : "2x" 62 | }, 63 | { 64 | "size" : "76x76", 65 | "idiom" : "ipad", 66 | "filename" : "OfficeUIFabric76.png", 67 | "scale" : "1x" 68 | }, 69 | { 70 | "size" : "76x76", 71 | "idiom" : "ipad", 72 | "filename" : "OfficeUIFabric76@2x.png", 73 | "scale" : "2x" 74 | }, 75 | { 76 | "size" : "83.5x83.5", 77 | "idiom" : "ipad", 78 | "filename" : "OfficeUIFabric83.5@2x.png", 79 | "scale" : "2x" 80 | } 81 | ], 82 | "info" : { 83 | "version" : 1, 84 | "author" : "xcode" 85 | } 86 | } -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric29.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric29.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric29@2x-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric29@2x-1.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric29@2x.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric29@3x.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric40.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric40.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric40@2x-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric40@2x-1.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric40@2x.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric40@3x.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric60@2x.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric60@3x.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric76.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric76.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric76@2x.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/AppIcon.appiconset/OfficeUIFabric83.5@2x.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/CircleIcon.imageset/CircleIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/CircleIcon.imageset/CircleIcon.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/CircleIcon.imageset/CircleIcon@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/CircleIcon.imageset/CircleIcon@2x.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/CircleIcon.imageset/CircleIcon@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/CircleIcon.imageset/CircleIcon@3x.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/CircleIcon.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "CircleIcon.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "CircleIcon@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "filename" : "CircleIcon@3x.png", 16 | "scale" : "3x" 17 | } 18 | ], 19 | "info" : { 20 | "version" : 1, 21 | "author" : "xcode" 22 | }, 23 | "properties" : { 24 | "template-rendering-intent" : "template" 25 | } 26 | } -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/CircleIconFilled.imageset/CircleIconFilled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/CircleIconFilled.imageset/CircleIconFilled.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/CircleIconFilled.imageset/CircleIconFilled@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/CircleIconFilled.imageset/CircleIconFilled@2x.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/CircleIconFilled.imageset/CircleIconFilled@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/CircleIconFilled.imageset/CircleIconFilled@3x.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/CircleIconFilled.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "CircleIconFilled.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "CircleIconFilled@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "filename" : "CircleIconFilled@3x.png", 16 | "scale" : "3x" 17 | } 18 | ], 19 | "info" : { 20 | "version" : 1, 21 | "author" : "xcode" 22 | }, 23 | "properties" : { 24 | "template-rendering-intent" : "template" 25 | } 26 | } -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/OfficeUIFabric.Person.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "OfficeUIFabric.Person.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | } 21 | } -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/OfficeUIFabric.Person.imageset/OfficeUIFabric.Person.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/OfficeUIFabric.Person.imageset/OfficeUIFabric.Person.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/OfficeUIFabric.TestImage.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "OfficeUIFabric.TestImage.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "OfficeUIFabric.TestImage@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "filename" : "OfficeUIFabric.TestImage@3x.png", 16 | "scale" : "3x" 17 | } 18 | ], 19 | "info" : { 20 | "version" : 1, 21 | "author" : "xcode" 22 | } 23 | } -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/OfficeUIFabric.TestImage.imageset/OfficeUIFabric.TestImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/OfficeUIFabric.TestImage.imageset/OfficeUIFabric.TestImage.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/OfficeUIFabric.TestImage.imageset/OfficeUIFabric.TestImage@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/OfficeUIFabric.TestImage.imageset/OfficeUIFabric.TestImage@2x.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/OfficeUIFabric.TestImage.imageset/OfficeUIFabric.TestImage@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/OfficeDev/office-ui-fabric-ios/c54cecca5181d8a56af658fbcd916b2e2474aae8/OfficeUIFabricDemo/OfficeUIFabricDemo/Assets.xcassets/OfficeUIFabric.TestImage.imageset/OfficeUIFabric.TestImage@3x.png -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Base.lproj/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Colors/ColorItemCell.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | class ColorItemCell: UITableViewCell { 6 | @IBOutlet weak var colorView: UIView! 7 | @IBOutlet weak var titleLabel: UILabel! 8 | @IBOutlet weak var hexLabel: UILabel! 9 | } 10 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Colors/ColorPaletteTableViewController.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | class ColorPaletteTableViewController: UITableViewController { 6 | 7 | internal var colorsType: ColorsDataSourceType = .palette 8 | private var colorsDataSource: ColorsDataSource? = nil 9 | 10 | override func viewDidLoad() { 11 | super.viewDidLoad() 12 | 13 | self.colorsDataSource = ColorsDataSource(type: self.colorsType) 14 | 15 | let tableView = self.view as! UITableView 16 | self.colorsDataSource?.setupTableView(tableView: tableView) 17 | } 18 | 19 | // MARK: - Table view data source 20 | 21 | override func numberOfSections(in tableView: UITableView) -> Int { 22 | return self.colorsDataSource!.numberOfSections(in: tableView) 23 | } 24 | 25 | override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { 26 | return self.colorsDataSource!.tableView(tableView, numberOfRowsInSection: section) 27 | } 28 | 29 | override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { 30 | return self.colorsDataSource!.tableView(tableView, cellForRowAt: indexPath) 31 | } 32 | 33 | override func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat { 34 | return self.colorsDataSource!.tableView(tableView, heightForHeaderInSection: section) 35 | } 36 | 37 | override func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? { 38 | return self.colorsDataSource!.tableView(tableView, viewForHeaderInSection: section) 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Colors/ColorsDataSource.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | internal enum ColorsDataSourceType : Int { 6 | case palette 7 | case hash 8 | } 9 | 10 | class ColorsDataSource: NSObject, UITableViewDataSource, UITableViewDelegate { 11 | 12 | // MARK: Colors List 13 | 14 | internal class ColorSectionItem { 15 | var title: String = "" 16 | var colors: [ColorItem] = [] 17 | init(title: String, colors: [ColorItem]) { 18 | self.title = title 19 | self.colors = colors 20 | } 21 | } 22 | 23 | internal class ColorItem { 24 | var title: String = "" 25 | var color: UIColor = UIColor() 26 | var hex: String = "" 27 | init(title: String, color: UIColor, hex: String) { 28 | self.title = title 29 | self.color = color 30 | self.hex = hex 31 | } 32 | } 33 | 34 | private var colorSections: [ColorSectionItem] = [] 35 | 36 | internal init(type: ColorsDataSourceType = .palette) { 37 | super.init() 38 | 39 | switch type { 40 | case .palette: 41 | self.colorSections = self.colorsFromPalette() 42 | case .hash: 43 | self.colorSections = self.colorsWithHash() 44 | } 45 | } 46 | 47 | private func colorsFromPalette() -> [ColorSectionItem] { 48 | return [ 49 | ColorSectionItem(title: "Theme Colors", colors: [ 50 | ColorItem(title: "Theme Darker", color: UIColor.msThemeDarker(), hex: "#004578"), 51 | ColorItem(title: "Theme Dark", color: UIColor.msThemeDark(), hex: "#005a9e"), 52 | ColorItem(title: "Theme Dark Alt", color: UIColor.msThemeDarkAlt(), hex: "#106ebe"), 53 | ColorItem(title: "Theme Primary", color: UIColor.msThemePrimary(), hex: "#0078d7"), 54 | ColorItem(title: "Theme Secondary", color: UIColor.msThemeSecondary(), hex: "#2b88d8"), 55 | ColorItem(title: "Theme Tertiary", color: UIColor.msThemeTertiary(), hex: "#71afe5"), 56 | ColorItem(title: "Theme Light", color: UIColor.msThemeLight(), hex: "#c7e0f4"), 57 | ColorItem(title: "Theme Lighter", color: UIColor.msThemeLighter(), hex: "#deecf9"), 58 | ColorItem(title: "Theme Lighter Alt", color: UIColor.msThemeLighterAlt(), hex: "#eff6fc") 59 | ]), 60 | ColorSectionItem(title: "Neutral Colors", colors: [ 61 | ColorItem(title: "Neutral Black", color: UIColor.msNeutralBlack(), hex: "#000000"), 62 | ColorItem(title: "Neutral Dark", color: UIColor.msNeutralDark(), hex: "#212121"), 63 | ColorItem(title: "Neutral Primary", color: UIColor.msNeutralPrimary(), hex: "#333333"), 64 | ColorItem(title: "Neutral Secondary", color: UIColor.msNeutralSecondary(), hex: "#666666"), 65 | ColorItem(title: "Neutral Secondary Alt", color: UIColor.msNeutralSecondaryAlt(), hex: "#767676"), 66 | ColorItem(title: "Neutral Tertiary", color: UIColor.msNeutralTertiary(), hex: "#a6a6a6"), 67 | ColorItem(title: "Neutral Tertiary Alt", color: UIColor.msNeutralTertiaryAlt(), hex: "#c8c8c8"), 68 | ColorItem(title: "Neutral Light", color: UIColor.msNeutralLight(), hex: "#eaeaea"), 69 | ColorItem(title: "Neutral Lighter", color: UIColor.msNeutralLighter(), hex: "#f4f4f4"), 70 | ColorItem(title: "Neutral Lighter Alt", color: UIColor.msNeutralLighterAlt(), hex: "#f8f8f8"), 71 | ColorItem(title: "Neutral White", color: UIColor.msNeutralWhite(), hex: "#ffffff") 72 | ]), 73 | ColorSectionItem(title: "Accent Colors", colors: [ 74 | ColorItem(title: "Accent Yellow", color: UIColor.msAccentYellow(), hex: "#ffb900"), 75 | ColorItem(title: "Accent Yellow Light", color: UIColor.msAccentYellowLight(), hex: "#fff100"), 76 | ColorItem(title: "Accent Orange", color: UIColor.msAccentOrange(), hex: "#d83b01"), 77 | ColorItem(title: "Accent Orange Light", color: UIColor.msAccentOrangeLight(), hex: "#ff8c00"), 78 | ColorItem(title: "Accent Red Dark", color: UIColor.msAccentRedDark(), hex: "#a80000"), 79 | ColorItem(title: "Accent Red", color: UIColor.msAccentRed(), hex: "#e81123"), 80 | ColorItem(title: "Accent Magenta Dark", color: UIColor.msAccentMagentaDark(), hex: "#5c005c"), 81 | ColorItem(title: "Accent Magenta", color: UIColor.msAccentMagenta(), hex: "#b4009e"), 82 | ColorItem(title: "Accent Magenta Light", color: UIColor.msAccentMagentaLight(), hex: "#e3008c"), 83 | ColorItem(title: "Accent Purple Dark", color: UIColor.msAccentPurpleDark(), hex: "#32145a"), 84 | ColorItem(title: "Accent Purple", color: UIColor.msAccentPurple(), hex: "#5c2d91"), 85 | ColorItem(title: "Accent Purple Light", color: UIColor.msAccentPurpleLight(), hex: "#b4a0ff"), 86 | ColorItem(title: "Accent Blue Dark", color: UIColor.msAccentBlueDark(), hex: "#002050"), 87 | ColorItem(title: "Accent Blue Mid", color: UIColor.msAccentBlueMid(), hex: "#00188f"), 88 | ColorItem(title: "Accent Blue", color: UIColor.msAccentBlue(), hex: "#0078d7"), 89 | ColorItem(title: "Accent Blue Light", color: UIColor.msAccentBlueLight(), hex: "#00bcf2"), 90 | ColorItem(title: "Accent Teal Dark", color: UIColor.msAccentTealDark(), hex: "#004b50"), 91 | ColorItem(title: "Accent Teal", color: UIColor.msAccentTeal(), hex: "#008272"), 92 | ColorItem(title: "Accent Teal Light", color: UIColor.msAccentTealLight(), hex: "#00b294"), 93 | ColorItem(title: "Accent Green Dark", color: UIColor.msAccentGreenDark(), hex: "#004b1c"), 94 | ColorItem(title: "Accent Green", color: UIColor.msAccentGreen(), hex: "#107c10"), 95 | ColorItem(title: "Accent Green Light", color: UIColor.msAccentGreenLight(), hex: "#bad80a") 96 | ]) 97 | ] 98 | } 99 | 100 | private func colorsWithHash() -> [ColorSectionItem] { 101 | return [ 102 | ColorSectionItem(title: "Hash Generated Colors", colors: [ 103 | ColorItem(title: "Hash color: \"Rosalind Summers\"", color: UIColor.msHashColor(hash: "Rosalind Summers"), hex: "\"Rosalind Summers\""), 104 | ColorItem(title: "Hash color: \"Karen Pruitt\"", color: UIColor.msHashColor(hash: "Karen Pruitt"), hex: "\"Karen Pruitt\""), 105 | ColorItem(title: "Hash color: \"Norris Beardsley\"", color: UIColor.msHashColor(hash: "Norris Beardsley"), hex: "\"Norris Beardsley\""), 106 | ColorItem(title: "Hash color: \"Nadine Terrell\"", color: UIColor.msHashColor(hash: "Nadine Terrell"), hex: "\"Nadine Terrell\""), 107 | ColorItem(title: "Hash color: \"Naomi Wyatt\"", color: UIColor.msHashColor(hash: "Naomi Wyatt"), hex: "\"Naomi Wyatt\""), 108 | ColorItem(title: "Hash color: \"Proseware, Inc.\"", color: UIColor.msHashColor(hash: "Proseware, Inc."), hex: "\"Proseware, Inc.\""), 109 | ColorItem(title: "Hash color: \"VanArsdel, Ltd.\"", color: UIColor.msHashColor(hash: "VanArsdel, Ltd."), hex: "\"VanArsdel, Ltd.\""), 110 | ColorItem(title: "Hash color: \"Wide World Importers\"", color: UIColor.msHashColor(hash: "Wide World Importers"), hex: "\"Wide World Importers\"") 111 | ]) 112 | ] 113 | } 114 | 115 | // MARK: SetUp 116 | 117 | let ColorsSectionHeaderId = "ColorsSectionHeaderId" 118 | 119 | internal func setupTableView(tableView: UITableView) { 120 | tableView.register(UINib(nibName: "ColorsSectionHeader", bundle: nil), forHeaderFooterViewReuseIdentifier: ColorsSectionHeaderId) 121 | } 122 | 123 | // MARK: UITableViewDataSource implementation 124 | 125 | internal func numberOfSections(in tableView: UITableView) -> Int { 126 | return self.colorSections.count 127 | } 128 | 129 | internal func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { 130 | return self.colorSections[section].colors.count 131 | } 132 | 133 | func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { 134 | let cell = tableView.dequeueReusableCell(withIdentifier: "ColorItemCellId", for: indexPath) as! ColorItemCell 135 | let colorItem = self.colorSections[(indexPath as NSIndexPath).section].colors[(indexPath as NSIndexPath).row] 136 | 137 | cell.titleLabel.text = colorItem.title 138 | cell.colorView.backgroundColor = colorItem.color 139 | cell.hexLabel.text = colorItem.hex 140 | 141 | return cell 142 | } 143 | 144 | // MARK: Header 145 | 146 | let ColorsSectionHeaderHeight: CGFloat = 26 147 | 148 | func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat { 149 | return ColorsSectionHeaderHeight 150 | } 151 | 152 | func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? { 153 | let header = tableView.dequeueReusableHeaderFooterView(withIdentifier: "ColorsSectionHeaderId") as! ColorsSectionHeader 154 | header.sectionTitle.text = self.colorSections[section].title 155 | header.bgView.backgroundColor = self.colorSections[section].colors.first?.color 156 | return header 157 | } 158 | } 159 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Colors/ColorsSectionHeader.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | class ColorsSectionHeader: UITableViewHeaderFooterView { 6 | @IBOutlet weak var bgView: UIView! 7 | @IBOutlet weak var sectionTitle: UILabel! 8 | } 9 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Colors/ColorsSectionHeader.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Components/InitialsView/InitialsView.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Components/InitialsView/InitialsViewItemCell.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | import OfficeUIFabricCore 5 | 6 | class InitialsViewItemCell: UITableViewCell { 7 | @IBOutlet weak var initialsView: InitialsView! 8 | @IBOutlet weak var titleLabel: UILabel! 9 | 10 | func updateWithTitle(title: String) { 11 | self.initialsView.setInitialsFromTitle(title: title) 12 | self.titleLabel.text = title 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Components/InitialsView/InitialsViewTableViewController.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | class InitialsViewTableViewController: UITableViewController { 6 | 7 | private let initials: [String] = [ 8 | "Rosalind Summers", 9 | "Karen Pruitt", 10 | "Norris Beardsley", 11 | "Nadine Terrell", 12 | "Naomi Wyatt", 13 | "Proseware, Inc.", 14 | "The Phone Company", 15 | "Wide World Importers" 16 | ] 17 | 18 | override func viewDidLoad() { 19 | super.viewDidLoad() 20 | } 21 | 22 | // MARK: - Table view data source 23 | 24 | override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { 25 | return self.initials.count 26 | } 27 | 28 | override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { 29 | let cell = tableView.dequeueReusableCell(withIdentifier: String(describing: InitialsViewItemCell.self), for: indexPath) as! InitialsViewItemCell 30 | cell.updateWithTitle(title: self.initials[(indexPath as NSIndexPath).row]) 31 | return cell 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Components/LogoView/LogoView.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Components/LogoView/LogoViewItemCell.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | import OfficeUIFabricCore 5 | 6 | class LogoViewItemCell: UITableViewCell { 7 | @IBOutlet weak var logoView: LogoView! 8 | @IBOutlet weak var titleLabel: UILabel! 9 | } 10 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Components/LogoView/LogoViewTableViewController.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | class LogoViewTableViewController: UITableViewController { 6 | 7 | private let logoViewItems: [Any?] = [ 8 | "Rosalind Summers", 9 | ("Norris Beardsley", UIImage(named: "OfficeUIFabric.Person")!), 10 | "Nadine Terrell", 11 | ("Test Image", UIImage(named: "OfficeUIFabric.TestImage")!) 12 | ] 13 | 14 | override func viewDidLoad() { 15 | super.viewDidLoad() 16 | } 17 | 18 | // MARK: - Table view data source 19 | 20 | override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { 21 | return self.logoViewItems.count 22 | } 23 | 24 | override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { 25 | let cell = tableView.dequeueReusableCell(withIdentifier: String(describing: LogoViewItemCell.self), for: indexPath) as! LogoViewItemCell 26 | if let (title, image) = self.logoViewItems[(indexPath as NSIndexPath).row] as? (String, UIImage) { 27 | cell.logoView.updateWithImage(image: image) 28 | cell.titleLabel.text = title 29 | } 30 | if let title = self.logoViewItems[(indexPath as NSIndexPath).row] as? String { 31 | cell.logoView.updateWithTitle(title: title) 32 | cell.titleLabel.text = title 33 | } 34 | return cell 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Customization/ButtonDemoViewController.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | class ButtonDemoViewController: UIViewController { 6 | @IBOutlet weak var standardButton: UIButton! 7 | @IBOutlet weak var toggleButton: UIButton! 8 | @IBOutlet weak var disabledButton: UIButton! 9 | @IBOutlet weak var primaryButton: UIButton! 10 | @IBOutlet weak var toggleIconButton: UIButton! 11 | @IBOutlet weak var disabledPrimaryButton: UIButton! 12 | 13 | override func viewDidLoad() { 14 | super.viewDidLoad() 15 | 16 | self.standardButton.msStandardButton() 17 | self.primaryButton.msPrimaryButton() 18 | 19 | self.toggleButton.msStandardButton() 20 | self.toggleIconButton.msStandardButton() 21 | 22 | self.disabledButton.msStandardButton() 23 | self.disabledPrimaryButton.msPrimaryButton() 24 | } 25 | 26 | @IBAction func toggleButtonTap(_ sender: AnyObject) { 27 | if let button = sender as? UIButton { 28 | button.isSelected = !button.isSelected 29 | button.tintColor = button.titleColor(for: button.isSelected ? UIControlState.selected : UIControlState()) 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Customization/LabelDemoViewController.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | import OfficeUIFabricCore 5 | 6 | class LabelDemoViewController: UIViewController { 7 | @IBOutlet weak var largeLabel: UILabel! 8 | @IBOutlet weak var mediumLabel: UILabel! 9 | @IBOutlet weak var smallLabel: UILabel! 10 | 11 | @IBOutlet weak var boldLabel: UILabel! 12 | 13 | @IBOutlet weak var colorLargeLabel: UILabel! 14 | @IBOutlet weak var colorMediumLabel: UILabel! 15 | @IBOutlet weak var colorSmallLabel: UILabel! 16 | 17 | override func viewDidLoad() { 18 | super.viewDidLoad() 19 | 20 | self.largeLabel.msLabel(style: MSFontStyle.XL) 21 | self.mediumLabel.msLabel(style: MSFontStyle.M) 22 | self.smallLabel.msLabel(style: MSFontStyle.XS) 23 | 24 | self.boldLabel.msLabel(style: MSFontStyle.M, fontWeight: MSFontWeight.Semibold) 25 | 26 | self.colorLargeLabel.msLabel(style: MSFontStyle.XL, textColor: UIColor.msThemeSecondary()) 27 | self.colorMediumLabel.msLabel(style: MSFontStyle.M, textColor: UIColor.msThemeSecondary()) 28 | self.colorSmallLabel.msLabel(style: MSFontStyle.XS, textColor: UIColor.msThemeSecondary()) 29 | } 30 | 31 | } 32 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Customization/TextFieldDemoViewController.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | import OfficeUIFabricCore 5 | 6 | class TextFieldDemoViewController: UIViewController { 7 | @IBOutlet weak var defaultBoxTextField: UITextField! 8 | @IBOutlet weak var defaultUnderlineTextField: UITextField! 9 | 10 | @IBOutlet weak var customBoxTextField: UITextField! 11 | @IBOutlet weak var customUnderlineTextField: UITextField! 12 | 13 | @IBOutlet weak var permPlaceholderBoxTextField: UITextField! 14 | @IBOutlet weak var permPlaceholderUnderlineTextField: UITextField! 15 | 16 | override func viewDidLoad() { 17 | super.viewDidLoad() 18 | 19 | self.defaultBoxTextField.msTextFieldBox() 20 | self.defaultBoxTextField.msTextFieldFontStyles(font: UIFont.msFont(style: MSFontStyle.L, weight: MSFontWeight.Regular)!) 21 | self.defaultBoxTextField.msTextFieldPlaceholderText(text: "Default Box TextField") 22 | 23 | self.defaultUnderlineTextField.msTextFieldUnderline() 24 | self.defaultUnderlineTextField.msTextFieldFontStyles(font: UIFont.msFont(style: MSFontStyle.L, weight: MSFontWeight.Regular)!) 25 | self.defaultUnderlineTextField.msTextFieldPlaceholderText(text: "Default Underline TextField") 26 | 27 | self.customBoxTextField.msTextFieldBox(borderColor: UIColor.msThemePrimary(), backgroundColor: UIColor.msThemePrimary().withAlphaComponent(0.05)) 28 | self.customBoxTextField.msTextFieldFontStyles(font: UIFont.msFont(style: MSFontStyle.MPlus)!, textColor: UIColor.msThemePrimary()) 29 | self.customBoxTextField.msTextFieldPlaceholderText(text: "Customized Box TextField", placeholderColor: UIColor.msThemeTertiary()) 30 | 31 | self.customUnderlineTextField.msTextFieldUnderline(borderColor: UIColor.msThemePrimary(), backgroundColor: UIColor.msThemePrimary().withAlphaComponent(0.05)) 32 | self.customUnderlineTextField.msTextFieldFontStyles(font: UIFont.msFont(style: MSFontStyle.MPlus)!, textColor: UIColor.msThemePrimary()) 33 | self.customUnderlineTextField.msTextFieldPlaceholderText(text: "Customized Underline TextField", placeholderColor: UIColor.msThemeTertiary()) 34 | 35 | self.permPlaceholderBoxTextField.msTextFieldBox() 36 | self.permPlaceholderBoxTextField.msTextFieldFontStyles(font: UIFont.msFont(style: MSFontStyle.MPlus)) 37 | self.permPlaceholderBoxTextField.msTextFieldPermanentPlaceholderText(text: "First Name", font: self.permPlaceholderBoxTextField.font) 38 | 39 | self.permPlaceholderUnderlineTextField.msTextFieldUnderline() 40 | self.permPlaceholderUnderlineTextField.msTextFieldFontStyles(font: UIFont.msFont(style: MSFontStyle.MPlus)) 41 | self.permPlaceholderUnderlineTextField.msTextFieldPermanentPlaceholderText(text: "Last Name", font: self.permPlaceholderBoxTextField.font) 42 | } 43 | 44 | @IBAction func hideKeyboard(_ sender: AnyObject) { 45 | self.defaultBoxTextField.resignFirstResponder() 46 | self.defaultUnderlineTextField.resignFirstResponder() 47 | self.customBoxTextField.resignFirstResponder() 48 | self.customUnderlineTextField.resignFirstResponder() 49 | self.permPlaceholderBoxTextField.resignFirstResponder() 50 | self.permPlaceholderUnderlineTextField.resignFirstResponder() 51 | } 52 | } 53 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Fonts/FontItemCell.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | class FontItemCell: UITableViewCell { 6 | @IBOutlet weak var previewLabel: UILabel! 7 | @IBOutlet weak var styleLabel: UILabel! 8 | @IBOutlet weak var sizeLabel: UILabel! 9 | @IBOutlet weak var fontWeightLabel: UILabel! 10 | } 11 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Fonts/FontsTableViewController.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | import OfficeUIFabricCore 5 | 6 | class FontsTableViewController: UITableViewController { 7 | 8 | internal class FontItem { 9 | var style: String = "" 10 | var font: UIFont = UIFont() 11 | var size: Int = 0 12 | var weight: String = "" 13 | init(style: String, font: UIFont, size: Int, weight: String) { 14 | self.style = style 15 | self.font = font 16 | self.size = size 17 | self.weight = weight 18 | } 19 | } 20 | 21 | private let fontItems: [FontItem] = [ 22 | FontItem(style: "SU", font: UIFont.msFont(style: MSFontStyle.SU)!, size: 42, weight: "Light"), 23 | FontItem(style: "XXL", font: UIFont.msFont(style: MSFontStyle.XXL)!, size: 28, weight: "Light"), 24 | FontItem(style: "XL", font: UIFont.msFont(style: MSFontStyle.XL)!, size: 21, weight: "Light"), 25 | FontItem(style: "L", font: UIFont.msFont(style: MSFontStyle.L)!, size: 17, weight: "SemiLight"), 26 | FontItem(style: "MPlus",font: UIFont.msFont(style: MSFontStyle.MPlus)!,size: 15, weight: "Regular"), 27 | FontItem(style: "M", font: UIFont.msFont(style: MSFontStyle.M)!, size: 14, weight: "Regular"), 28 | FontItem(style: "SPlus",font: UIFont.msFont(style: MSFontStyle.SPlus)!,size: 13, weight: "Regular"), 29 | FontItem(style: "S", font: UIFont.msFont(style: MSFontStyle.S)!, size: 12, weight: "Regular"), 30 | FontItem(style: "XS", font: UIFont.msFont(style: MSFontStyle.XS)!, size: 11, weight: "Regular"), 31 | FontItem(style: "MI", font: UIFont.msFont(style: MSFontStyle.MI)!, size: 10, weight: "Semibold") 32 | ] 33 | 34 | override func viewDidLoad() { 35 | super.viewDidLoad() 36 | } 37 | 38 | // MARK: - Table view data source 39 | 40 | override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { 41 | return self.fontItems.count 42 | } 43 | 44 | override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { 45 | let cell = tableView.dequeueReusableCell(withIdentifier: "FontItemCellId", for: indexPath) as! FontItemCell 46 | 47 | let fontItem = self.fontItems[(indexPath as NSIndexPath).row] 48 | 49 | cell.styleLabel.text = fontItem.style 50 | cell.sizeLabel.text = "\(fontItem.size)pt" 51 | cell.fontWeightLabel.text = fontItem.weight 52 | cell.previewLabel.font = fontItem.font 53 | 54 | return cell 55 | } 56 | } 57 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Main/DemoItemCell.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | class DemoItemCell: UITableViewCell { 6 | @IBOutlet weak var itemTitle: UILabel! 7 | 8 | override func awakeFromNib() { 9 | super.awakeFromNib() 10 | self.setSelectionColor(selectionColor: UIColor.msNeutralTertiaryAlt()) 11 | } 12 | 13 | private func setSelectionColor(selectionColor: UIColor) { 14 | let backgroundSelectionView = UIView() 15 | backgroundSelectionView.backgroundColor = selectionColor 16 | self.selectedBackgroundView = backgroundSelectionView 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Main/DemoSectionHeader.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | class DemoSectionHeader: UITableViewHeaderFooterView { 6 | @IBOutlet weak var sectionTitle: UILabel! 7 | } 8 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Main/DemoSectionHeader.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/DemoControllers/Main/MainTableViewController.swift: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. See LICENSE in the project root for license information. 2 | 3 | import UIKit 4 | 5 | class MainTableViewController: UITableViewController { 6 | 7 | // MARK: List of Demos 8 | 9 | internal class DemoLinkSectionItem { 10 | var title: String = "" 11 | var demos: [DemoLinkItem] = [] 12 | init(title: String, demos: [DemoLinkItem]) { 13 | self.title = title 14 | self.demos = demos 15 | } 16 | } 17 | 18 | internal class DemoLinkItem { 19 | var title: String = "" 20 | var segueId: String? 21 | init(title: String, segueId: String? = nil) { 22 | self.title = title 23 | self.segueId = segueId 24 | } 25 | } 26 | 27 | static let ShowColorsPaletteSegueId: String = "ShowColorsPaletteSegueId" 28 | 29 | let demoSections: [DemoLinkSectionItem] = [ 30 | DemoLinkSectionItem(title: "Colors", demos: [ 31 | DemoLinkItem(title: "Colors Palette", segueId: ShowColorsPaletteSegueId), 32 | DemoLinkItem(title: "Colors from Hash String", segueId: ShowColorsPaletteSegueId) 33 | ]), 34 | DemoLinkSectionItem(title: "Fonts", demos: [ 35 | DemoLinkItem(title: "Font Styles", segueId: "ShowFontsSegueId") 36 | ]), 37 | DemoLinkSectionItem(title: "Customization", demos: [ 38 | DemoLinkItem(title: "UIButton", segueId: "ShowButtonSegueId"), 39 | DemoLinkItem(title: "UILabel", segueId: "ShowLabelSegueId"), 40 | DemoLinkItem(title: "UITextField", segueId: "ShowTextFieldSegueId") 41 | ]), 42 | DemoLinkSectionItem(title: "Components: Common", demos: [ 43 | DemoLinkItem(title: "InitialsView", segueId: "ShowInitialsViewSegueId"), 44 | DemoLinkItem(title: "LogoView", segueId: "ShowLogoViewSegueId") 45 | ]) 46 | ] 47 | 48 | // MARK: - Customization 49 | 50 | let DemoSectionHeaderHeight: CGFloat = 26 51 | 52 | override func viewDidLoad() { 53 | super.viewDidLoad() 54 | 55 | let tableView = self.view as! UITableView 56 | tableView.register(UINib(nibName: "DemoSectionHeader", bundle: nil), forHeaderFooterViewReuseIdentifier: "DemoSectionHeaderId") 57 | } 58 | 59 | // MARK: - Table view data source 60 | 61 | override func numberOfSections(in tableView: UITableView) -> Int { 62 | return self.demoSections.count 63 | } 64 | 65 | override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { 66 | return self.demoSections[section].demos.count 67 | } 68 | 69 | override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { 70 | let cell = tableView.dequeueReusableCell(withIdentifier: "DemoItemCellId", for: indexPath) as! DemoItemCell 71 | let demoItem = self.demoSections[(indexPath as NSIndexPath).section].demos[(indexPath as NSIndexPath).row] 72 | cell.itemTitle.text = demoItem.title 73 | return cell 74 | } 75 | 76 | // MARK: Header 77 | 78 | override func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat { 79 | return DemoSectionHeaderHeight 80 | } 81 | 82 | override func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? { 83 | let header = tableView.dequeueReusableHeaderFooterView(withIdentifier: "DemoSectionHeaderId") as! DemoSectionHeader 84 | header.sectionTitle.text = self.demoSections[section].title 85 | return header 86 | } 87 | 88 | // MARK: Actions 89 | 90 | override func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) { 91 | if let segueId = self.demoSections[(indexPath as NSIndexPath).section].demos[(indexPath as NSIndexPath).row].segueId { 92 | self.performSegue(withIdentifier: segueId, sender: self) 93 | } 94 | 95 | tableView.deselectRow(at: indexPath, animated: true) 96 | } 97 | 98 | override func prepare(for segue: UIStoryboardSegue, sender: Any?) { 99 | if segue.identifier == MainTableViewController.ShowColorsPaletteSegueId { 100 | let controller = segue.destination as! ColorPaletteTableViewController 101 | if let type = ColorsDataSourceType(rawValue: (tableView.indexPathForSelectedRow! as NSIndexPath).row) { 102 | controller.colorsType = type 103 | } 104 | } 105 | } 106 | } 107 | -------------------------------------------------------------------------------- /OfficeUIFabricDemo/OfficeUIFabricDemo/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | UIViewControllerBasedStatusBarAppearance 6 | 7 | CFBundleDevelopmentRegion 8 | en 9 | CFBundleExecutable 10 | $(EXECUTABLE_NAME) 11 | CFBundleIdentifier 12 | $(PRODUCT_BUNDLE_IDENTIFIER) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | $(PRODUCT_NAME) 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | 1.0 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | 1 25 | LSRequiresIPhoneOS 26 | 27 | UILaunchStoryboardName 28 | LaunchScreen 29 | UIMainStoryboardFile 30 | Main 31 | UIRequiredDeviceCapabilities 32 | 33 | armv7 34 | 35 | UIStatusBarStyle 36 | UIStatusBarStyleLightContent 37 | UISupportedInterfaceOrientations 38 | 39 | UIInterfaceOrientationPortrait 40 | UIInterfaceOrientationLandscapeLeft 41 | UIInterfaceOrientationLandscapeRight 42 | 43 | UISupportedInterfaceOrientations~ipad 44 | 45 | UIInterfaceOrientationPortrait 46 | UIInterfaceOrientationPortraitUpsideDown 47 | UIInterfaceOrientationLandscapeLeft 48 | UIInterfaceOrientationLandscapeRight 49 | 50 | 51 | 52 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # [ARCHIVED] [Office UI Fabric iOS Core](http://dev.office.com/fabric) 2 | 3 | **Note:** This repo is archived and no longer actively maintained. Security vulnerabilities may exist in the project, or its dependencies. If you plan to reuse or run any code from this repo, be sure to perform appropriate security checks on the code or dependencies first. Do not use this project as the starting point of a production Office Add-in. Always start your production code by using the Office/SharePoint development workload in Visual Studio, or the [Yeoman generator for Office Add-ins](https://github.com/OfficeDev/generator-office), and follow security best practices as you develop the add-in. 4 | 5 | ##### The iOS UI framework for building experiences for Office and Office 365. 6 | 7 | Fabric for iOS is a library that provides the Office UI experience for the native iOS platform. It contains tokens like [Colors](#colors) and [Typography](#typography), as well as customization for native controls like the [UIButton](#uibutton) and [UILabel](#uilabel) (with more coming soon), all from the official design language used in Office and Office 365 products. 8 | 9 | ## Install and use Office UI Fabric 10 | 11 | ### 1. Using CocoaPods 12 | 13 | ```ruby 14 | pod 'OfficeUIFabricCore', '~> 0.1.6’ 15 | ``` 16 | 17 | ### 2. Manual installation 18 | 19 | 2.1. Download the latest changes from the [Office UI Fabric iOS](https://github.com/OfficeDev/Office-UI-Fabric-iOS) repository. 20 | 21 | 2.2. Move the `OfficeUIFabricCore` folder into your project folder. 22 | 23 | 2.3. Drag and drop `OfficeUIFabricCore/OfficeUIFabricCore.xcodeproj` into your xcode project. 24 | 25 | 2.4. Select in Xcode **your project** -> **your target** -> **General** -> **Embedded Binaries** -> **add "OfficeUIFabricCore.framework"**. 26 | 27 | Import the library to use it: 28 | 29 | ```swift 30 | import OfficeUIFabricCore 31 | ``` 32 | 33 | ## Tokens 34 | 35 | ### Colors 36 | 37 | You can use the `UIColor` extension to access colors from the Office color palette: 38 | 39 | ```swift 40 | UIColor.msThemePrimary() 41 | UIColor.msNeutralSecondaryAlt() 42 | UIColor.msAccentBlueLight() 43 | 44 | ``` 45 | 46 | For the full list of colors, see the [Styles page](http://dev.office.com/fabric/styles#color) on the Fabric website. 47 | 48 | When you have a list of items that don't all have images (for example, address book contacts or a list of music bands), you can use the `HashColor` algorithm to generate random colors: 49 | 50 | ```swift 51 | UIColor.msHashColor("Karen Pruitt") 52 | UIColor.msHashColor("Norris Beardsley") 53 | UIColor.msHashColor("Proseware, Inc.") 54 | ``` 55 | 56 | ### Typography 57 | 58 | Fabric uses several font styles. You can see the full list on the [Typography styles](http://dev.office.com/fabric/styles#typography) page of the Fabric website. 59 | 60 | Fabric iOS uses [Apple's SanFrancisco font](https://developer.apple.com/fonts/). 61 | 62 | Use the `UIFont` extension to get fonts for different styles: 63 | 64 | ```swift 65 | UIFont.msFont(style: MSFontStyle.SU) 66 | UIFont.msFont(style: MSFontStyle.XXL) 67 | UIFont.msFont(style: MSFontStyle.SPlus) 68 | ``` 69 | 70 | The font returned will be the preferred font weight. You can also specify a different font weight: 71 | 72 | ```swift 73 | UIFont.msFont(style: MSFontStyle.XL, weight: MSFontWeight.Light) 74 | UIFont.msFont(style: MSFontStyle.MPlus, weight: MSFontWeight.Semibold) 75 | UIFont.msFont(style: MSFontStyle.L, weight: MSFontWeight.Thin) 76 | ``` 77 | >Note: The font weight works only for iOS 8.2 and later. For earlier versions of iOS, the font will be regular weight. 78 | 79 | ### Icons 80 | 81 | To be consistent with other design tokens, you can use recommended icon sizes with specific line weights: 82 | 83 | ``` 84 | TabBar Icons: 30x30pt, line weight: 1 85 | Toolbar Icons: 28x28pt, line weight: 1 86 | NavigationBar Icons: 20x20pt, line weight: 1 87 | ``` 88 | 89 | In general, we recommend that you use outline icons rather than solid icons. Use solid icons for different icon states (such as following/not following). 90 | 91 | ## Native control customization 92 | 93 | ### UIButton 94 | 95 | You can use the `UIButtonMS` extension to customize your UI buttons: 96 | 97 | ```swift 98 | self.myButton.msStandardButton() 99 | self.myOtherButton.msPrimaryButton() 100 | ``` 101 | 102 | ![Image showing three standard and three primary UIButton colors](https://raw.githubusercontent.com/OfficeDev/Office-UI-Fabric-iOS/master/DocsAssets/ButtonExample.png) 103 | 104 | To customize the button color, you can pass parameters to `msStandardButton` or `msPrimaryButton`: 105 | 106 | ```swift 107 | self.standardButton.msStandardButton(UIColor.msAccentTeal(), disabledColor: UIColor.msAccentTealLight()) 108 | 109 | self.primaryButton.msPrimaryButton(UIColor.msAccentTeal(), selectedColor: UIColor.msAccentTealDark(), disabledColor: UIColor.msAccentTealLight()) 110 | ``` 111 | You can also apply a font and/or an image to your button in a standard way: 112 | 113 | ```swift 114 | self.toggleIconButton.titleLabel?.font = UIFont.msFont(MSFontStyle.L) 115 | 116 | self.toggleIconButton.setImage(UIImage(named: "MyToggleImage"), forState: .Normal) 117 | 118 | self.toggleIconButton.setImage(UIImage(named: "MyToggleImageSelected"), forState: .Selected) 119 | ``` 120 | 121 | ### UILabel 122 | 123 | You can use the `UILabelMS` extension to customize your UI labels: 124 | 125 | ```swift 126 | self.myLabel.msLabel(MSFontStyle.XL, fontWeight: MSFontWeight.SemiLight, textColor: UIColor.msThemePrimary()) 127 | 128 | self.myBoldLabel.msLabel(fontWeight: MSFontWeight.Semibold) 129 | 130 | self.mySmallLabel.msLabel(MSFontStyle.XS) 131 | 132 | self.myColorLabel.msLabel(textColor: UIColor.msThemeSecondary()) 133 | 134 | self.myColorSmallLabel.msLabel(MSFontStyle.XS, textColor: UIColor.msThemeSecondary()) 135 | ``` 136 | 137 | ![Image showing large, medium, and small UI labels in several colors](https://raw.githubusercontent.com/OfficeDev/Office-UI-Fabric-iOS/master/DocsAssets/LabelExample.png) 138 | 139 | ### UITextField 140 | 141 | You can use `UITextFieldMSExtension` to customize `UITextField`s in your project. 142 | 143 | ![Image showing customized text fields with box and underline styles](https://raw.githubusercontent.com/OfficeDev/Office-UI-Fabric-iOS/master/DocsAssets/TextFieldExample.png) 144 | 145 | `UITextField` customization consist of three components: 146 | 147 | * TextField Form 148 | * Text Style 149 | * Placeholder Text Style 150 | 151 | #### 1. Define the form: 152 | 153 | You can use `Box` or `Underline` style for your text field: 154 | ```swift 155 | self.myTextField.msTextFieldBox() 156 | 157 | self.myTextField.msTextFieldBox(borderColor: UIColor, backgroundColor: UIColor, leftPadding: CGFloat) 158 | ``` 159 | or 160 | ```swift 161 | self.myTextField.msTextFieldUnderline() 162 | 163 | self.myTextField.msTextFieldUnderline(borderColor: UIColor, backgroundColor: UIColor, leftPadding: CGFloat) 164 | ``` 165 | 166 | #### 2. Text Style: 167 | 168 | To apply text style to your `UITextField`: 169 | 170 | ```swift 171 | self.myTextField.msTextFieldFontStyles() 172 | 173 | self.myTextField.msTextFieldFontStyles(style: MSFontStyle, textColor: UIColor) 174 | 175 | self.myTextField.msTextFieldFontStyles(style: MSFontStyle, fontWeight: MSFontWeight, textColor: UIColor) 176 | 177 | self.myTextField.msTextFieldFontStyles(font: UIFont?, textColor: UIColor) 178 | ``` 179 | 180 | #### 3. Placeholder Text Style: 181 | 182 | You can use either "Placeholder text" in your `UITextField` or permanent "placeholder": 183 | 184 | ```swift 185 | // Placeholder text 186 | self.myTextField.msTextFieldPlaceholderText(text: String) 187 | 188 | self.myTextField.msTextFieldPlaceholderText(text: String, placeholderColor: UIColor, font: UIFont?) 189 | 190 | // Permanent placeholder 191 | self.myTextField.msTextFieldPermanentPlaceholderText(text: String) 192 | 193 | self.myTextField.msTextFieldPermanentPlaceholderText(text: String, placeholderColor: UIColor, font: UIFont?, padding: CGFloat) 194 | ``` 195 | 196 | ## Components 197 | 198 | ### InitialsView 199 | 200 | Use the InitialsView component to create a colored box with initials from a string: 201 | 202 | ``` 203 | self.initialsView.setInitialsFromTitle(title) 204 | ``` 205 | 206 | Use `UIColor.msHashColor(title)` to set the background color. 207 | 208 | ![Image that shows two InitialsView components with initials from the string in different colors](https://raw.githubusercontent.com/OfficeDev/Office-UI-Fabric-iOS/master/DocsAssets/InitialsViewExample.png) 209 | 210 | ### LogoView 211 | 212 | Use the LogoView component to create a colored box with initials or an image. This component contains `InitialsView`, `UIImageView`, and logic to show both of them based on input. Use this component when you have a list of items that don't all have images such as an address book. 213 | 214 | 215 | ``` 216 | self.logoView.updateWithTitle(title) 217 | ``` 218 | 219 | or 220 | 221 | ``` 222 | self.logoView.updateWithImage(image) 223 | ``` 224 | 225 | ![Image that shows a LogoView component with an InitialsView and a UIImageView](https://raw.githubusercontent.com/OfficeDev/Office-UI-Fabric-iOS/master/DocsAssets/LogoViewExample.png) 226 | 227 | 228 | ## Contribute to Fabric 229 | 230 | Post bug reports, feature requests, and questions on the [issue tracker](https://github.com/OfficeDev/Office-UI-Fabric-iOS/issues). 231 | 232 | 233 | ## Licenses 234 | 235 | All files on the Office UI Fabric GitHub repository are subject to the MIT license. Please read the License file at the root of the project. 236 | 237 | 238 | ## Changelog 239 | We use [GitHub Releases](https://github.com/blog/1547-release-your-software) to manage our releases, including the changelog between every release. You'll find a complete list of additions, fixes, and changes since the 1.0 release on the [Releases page](https://github.com/OfficeDev/Office-UI-Fabric-iOS/releases). 240 | 241 | - - - 242 | 243 | This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments. 244 | --------------------------------------------------------------------------------