From c3c8d15c9f0b9e792dde4d12be6385ef837f47be Mon Sep 17 00:00:00 2001 From: harrieshin Date: Wed, 15 Apr 2020 09:06:18 -0700 Subject: [PATCH] rename OfficeUIFabricFramework to FluentUIFramework (#14) * Find and replace "OfficeUIFabric" to "FluentUI" * update image name --- .../FluentUI.Demo.xcodeproj/project.pbxproj | 10 +++---- .../FluentUI.Demo/AppDelegate.swift | 2 +- ...leViewHeaderFooterViewDemoController.swift | 2 +- ...ader.h => FluentUI.Demo-Bridging-Header.h} | 0 .../FluentUI.Demo/MasterViewController.swift | 2 +- .../AppLogo.pdf} | Bin .../AppLogoLarge.pdf} | Bin .../Contents.json | 4 +-- .../Base.lproj/LaunchScreen.storyboard | 8 ++--- ...IFabricTests.swift => FluentUITests.swift} | 2 +- ios/FluentUI.xcodeproj/project.pbxproj | 28 +++++++++--------- ios/FluentUI/Core/Colors.swift | 2 +- ...UIFabric.swift => FluentUIFramework.swift} | 4 +-- .../Extensions/String+Extension.swift | 2 +- .../Extensions/UIImage+Extensions.swift | 2 +- ios/FluentUI/FluentUI.h | 9 ++++++ .../Navigation/Views/MSLargeTitleView.swift | 2 +- ios/FluentUI/OfficeUIFabric.h | 16 ---------- .../MSCardPresenterNavigationController.swift | 2 +- ios/FluentUI/Table View/MSBooleanCell.swift | 2 +- 20 files changed, 46 insertions(+), 53 deletions(-) rename ios/FluentUI.Demo/FluentUI.Demo/{OfficeUIFabric.Demo-Bridging-Header.h => FluentUI.Demo-Bridging-Header.h} (100%) rename ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/{FabricLogo.imageset/fabricLogo.pdf => AppLogo.imageset/AppLogo.pdf} (100%) rename ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/{FabricLogo.imageset/fabricLogoLarge.pdf => AppLogo.imageset/AppLogoLarge.pdf} (100%) rename ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/{FabricLogo.imageset => AppLogo.imageset}/Contents.json (82%) rename ios/FluentUI.Tests/{OfficeUIFabricTests.swift => FluentUITests.swift} (95%) rename ios/FluentUI/Core/{OfficeUIFabric.swift => FluentUIFramework.swift} (96%) create mode 100644 ios/FluentUI/FluentUI.h delete mode 100644 ios/FluentUI/OfficeUIFabric.h diff --git a/ios/FluentUI.Demo/FluentUI.Demo.xcodeproj/project.pbxproj b/ios/FluentUI.Demo/FluentUI.Demo.xcodeproj/project.pbxproj index 63813eb1ed..e17943aaba 100644 --- a/ios/FluentUI.Demo/FluentUI.Demo.xcodeproj/project.pbxproj +++ b/ios/FluentUI.Demo/FluentUI.Demo.xcodeproj/project.pbxproj @@ -143,7 +143,7 @@ FD7254EC21471A3F002F4069 /* MSDateTimePickerDemoController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MSDateTimePickerDemoController.swift; sourceTree = ""; }; FD7DF06121FB941400857267 /* MSTooltipDemoController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MSTooltipDemoController.swift; sourceTree = ""; }; FDCF7C8221BF35680058E9E6 /* MSSegmentedControlDemoController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MSSegmentedControlDemoController.swift; sourceTree = ""; }; - FDDD73FA22C6D86A00A9D995 /* OfficeUIFabric.Demo-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "OfficeUIFabric.Demo-Bridging-Header.h"; sourceTree = ""; }; + FDDD73FA22C6D86A00A9D995 /* FluentUI.Demo-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "FluentUI.Demo-Bridging-Header.h"; sourceTree = ""; }; FDDD73FB22C6D86B00A9D995 /* ObjectiveCDemoController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ObjectiveCDemoController.m; sourceTree = ""; }; FDDD73FC22C6D86B00A9D995 /* ObjectiveCDemoController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ObjectiveCDemoController.h; sourceTree = ""; }; /* End PBXFileReference section */ @@ -175,7 +175,7 @@ isa = PBXGroup; children = ( A5CEC21D20E436F20016922A /* Info.plist */, - FDDD73FA22C6D86A00A9D995 /* OfficeUIFabric.Demo-Bridging-Header.h */, + FDDD73FA22C6D86A00A9D995 /* FluentUI.Demo-Bridging-Header.h */, ); name = Configuration; sourceTree = ""; @@ -616,7 +616,7 @@ PRODUCT_NAME = FluentUI.Demo; PROVISIONING_PROFILE = "4596e7d8-5232-4b9f-82bf-63883e38cd5c"; PROVISIONING_PROFILE_SPECIFIER = "Office Fabric Demo Dogfood Distribution"; - SWIFT_OBJC_BRIDGING_HEADER = "FluentUI.Demo/OfficeUIFabric.Demo-Bridging-Header.h"; + SWIFT_OBJC_BRIDGING_HEADER = "FluentUI.Demo/FluentUI.Demo-Bridging-Header.h"; SWIFT_VERSION = 5.0; TARGETED_DEVICE_FAMILY = "1,2"; }; @@ -759,7 +759,7 @@ PRODUCT_NAME = FluentUI.Demo; PROVISIONING_PROFILE = "63d62159-2691-4b44-9553-b668cc1746c1"; PROVISIONING_PROFILE_SPECIFIER = "Office UI Fabric Demo Development"; - SWIFT_OBJC_BRIDGING_HEADER = "FluentUI.Demo/OfficeUIFabric.Demo-Bridging-Header.h"; + SWIFT_OBJC_BRIDGING_HEADER = "FluentUI.Demo/FluentUI.Demo-Bridging-Header.h"; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; SWIFT_VERSION = 5.0; TARGETED_DEVICE_FAMILY = "1,2"; @@ -785,7 +785,7 @@ PRODUCT_NAME = FluentUI.Demo; PROVISIONING_PROFILE = "63d62159-2691-4b44-9553-b668cc1746c1"; PROVISIONING_PROFILE_SPECIFIER = "Office UI Fabric Demo Development"; - SWIFT_OBJC_BRIDGING_HEADER = "FluentUI.Demo/OfficeUIFabric.Demo-Bridging-Header.h"; + SWIFT_OBJC_BRIDGING_HEADER = "FluentUI.Demo/FluentUI.Demo-Bridging-Header.h"; SWIFT_VERSION = 5.0; TARGETED_DEVICE_FAMILY = "1,2"; }; diff --git a/ios/FluentUI.Demo/FluentUI.Demo/AppDelegate.swift b/ios/FluentUI.Demo/FluentUI.Demo/AppDelegate.swift index 0b34e0e965..6388acfcbd 100644 --- a/ios/FluentUI.Demo/FluentUI.Demo/AppDelegate.swift +++ b/ios/FluentUI.Demo/FluentUI.Demo/AppDelegate.swift @@ -22,7 +22,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate, UISplitViewControllerDele var window: UIWindow? func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { - OfficeUIFabricFramework.initializeAppearance() + FluentUIFramework.initializeAppearance() let splitViewController = window!.rootViewController as! UISplitViewController let masterContainer = splitViewController.viewControllers.first as! UINavigationController diff --git a/ios/FluentUI.Demo/FluentUI.Demo/Demos/MSTableViewHeaderFooterViewDemoController.swift b/ios/FluentUI.Demo/FluentUI.Demo/Demos/MSTableViewHeaderFooterViewDemoController.swift index 8babd40ba0..a1c96e9c8a 100644 --- a/ios/FluentUI.Demo/FluentUI.Demo/Demos/MSTableViewHeaderFooterViewDemoController.swift +++ b/ios/FluentUI.Demo/FluentUI.Demo/Demos/MSTableViewHeaderFooterViewDemoController.swift @@ -106,7 +106,7 @@ extension MSTableViewHeaderFooterViewDemoController: UITableViewDelegate { let title = NSMutableAttributedString(string: section.footerText) let range = (title.string as NSString).range(of: section.footerLinkText) if range.location != -1 { - title.addAttribute(.link, value: "https://github.com/OfficeDev/ui-fabric-ios", range: range) + title.addAttribute(.link, value: "https://github.com/microsoft/fluentui-apple", range: range) } footer.setup(style: .footer, attributedTitle: title) diff --git a/ios/FluentUI.Demo/FluentUI.Demo/OfficeUIFabric.Demo-Bridging-Header.h b/ios/FluentUI.Demo/FluentUI.Demo/FluentUI.Demo-Bridging-Header.h similarity index 100% rename from ios/FluentUI.Demo/FluentUI.Demo/OfficeUIFabric.Demo-Bridging-Header.h rename to ios/FluentUI.Demo/FluentUI.Demo/FluentUI.Demo-Bridging-Header.h diff --git a/ios/FluentUI.Demo/FluentUI.Demo/MasterViewController.swift b/ios/FluentUI.Demo/FluentUI.Demo/MasterViewController.swift index 19762f5a97..92ab8793df 100644 --- a/ios/FluentUI.Demo/FluentUI.Demo/MasterViewController.swift +++ b/ios/FluentUI.Demo/FluentUI.Demo/MasterViewController.swift @@ -28,7 +28,7 @@ class MasterViewController: UITableViewController { let titleView = MSTwoLineTitleView() titleView.setup( title: navigationItem.title ?? "", - subtitle: OfficeUIFabricFramework.bundle.object(forInfoDictionaryKey: "CFBundleShortVersionString") as? String + subtitle: FluentUIFramework.bundle.object(forInfoDictionaryKey: "CFBundleShortVersionString") as? String ) navigationItem.titleView = titleView diff --git a/ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/FabricLogo.imageset/fabricLogo.pdf b/ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/AppLogo.imageset/AppLogo.pdf similarity index 100% rename from ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/FabricLogo.imageset/fabricLogo.pdf rename to ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/AppLogo.imageset/AppLogo.pdf diff --git a/ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/FabricLogo.imageset/fabricLogoLarge.pdf b/ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/AppLogo.imageset/AppLogoLarge.pdf similarity index 100% rename from ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/FabricLogo.imageset/fabricLogoLarge.pdf rename to ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/AppLogo.imageset/AppLogoLarge.pdf diff --git a/ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/FabricLogo.imageset/Contents.json b/ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/AppLogo.imageset/Contents.json similarity index 82% rename from ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/FabricLogo.imageset/Contents.json rename to ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/AppLogo.imageset/Contents.json index 060e258d3f..5d355af1e3 100644 --- a/ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/FabricLogo.imageset/Contents.json +++ b/ios/FluentUI.Demo/FluentUI.Demo/Resources/Assets.xcassets/AppLogo.imageset/Contents.json @@ -2,7 +2,7 @@ "images" : [ { "idiom" : "universal", - "filename" : "fabricLogo.pdf" + "filename" : "AppLogo.pdf" }, { "idiom" : "universal", @@ -14,7 +14,7 @@ }, { "idiom" : "universal", - "filename" : "fabricLogoLarge.pdf", + "filename" : "AppLogoLarge.pdf", "width-class" : "regular", "height-class" : "regular" } diff --git a/ios/FluentUI.Demo/FluentUI.Demo/Resources/Base.lproj/LaunchScreen.storyboard b/ios/FluentUI.Demo/FluentUI.Demo/Resources/Base.lproj/LaunchScreen.storyboard index ebe828c79c..68b4da8019 100644 --- a/ios/FluentUI.Demo/FluentUI.Demo/Resources/Base.lproj/LaunchScreen.storyboard +++ b/ios/FluentUI.Demo/FluentUI.Demo/Resources/Base.lproj/LaunchScreen.storyboard @@ -1,9 +1,9 @@ - + - + @@ -16,7 +16,7 @@ - + @@ -39,7 +39,7 @@ - + diff --git a/ios/FluentUI.Tests/OfficeUIFabricTests.swift b/ios/FluentUI.Tests/FluentUITests.swift similarity index 95% rename from ios/FluentUI.Tests/OfficeUIFabricTests.swift rename to ios/FluentUI.Tests/FluentUITests.swift index 55ff13433a..1668d33bbb 100644 --- a/ios/FluentUI.Tests/OfficeUIFabricTests.swift +++ b/ios/FluentUI.Tests/FluentUITests.swift @@ -6,7 +6,7 @@ import XCTest @testable import FluentUI -class OfficeUIFabricTests: XCTestCase { +class FluentUITests: XCTestCase { override func setUp() { super.setUp() // Put setup code here. This method is called before the invocation of each test method in the class. diff --git a/ios/FluentUI.xcodeproj/project.pbxproj b/ios/FluentUI.xcodeproj/project.pbxproj index d113eba873..bf9cc09608 100644 --- a/ios/FluentUI.xcodeproj/project.pbxproj +++ b/ios/FluentUI.xcodeproj/project.pbxproj @@ -48,7 +48,7 @@ 8FD0118B228A82A600D25925 /* MSCalendarConfiguration.swift in Sources */ = {isa = PBXBuildFile; fileRef = FDF41ED82141A02200EC527C /* MSCalendarConfiguration.swift */; }; 8FD0118C228A82A600D25925 /* MSDayOfMonth.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD777528219E3F6C00033D58 /* MSDayOfMonth.swift */; }; 8FD0118D228A82A600D25925 /* Obscurable.swift in Sources */ = {isa = PBXBuildFile; fileRef = FDA1AF8E21484A26001AE720 /* Obscurable.swift */; }; - 8FD0118E228A82A600D25925 /* OfficeUIFabric.swift in Sources */ = {isa = PBXBuildFile; fileRef = A559BB82212B7D870055E107 /* OfficeUIFabric.swift */; }; + 8FD0118E228A82A600D25925 /* FluentUIFramework.swift in Sources */ = {isa = PBXBuildFile; fileRef = A559BB82212B7D870055E107 /* FluentUIFramework.swift */; }; 8FD0118F228A82A600D25925 /* MSDateTimePicker.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD77752F21A490BA00033D58 /* MSDateTimePicker.swift */; }; 8FD01190228A82A600D25925 /* DateTimePicker.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD1FAE1A2272464B00A5DBA4 /* DateTimePicker.swift */; }; 8FD01191228A82A600D25925 /* MSDatePickerController.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD4F2A1F214AE20400C437D6 /* MSDatePickerController.swift */; }; @@ -106,7 +106,7 @@ A542A9D9226FC01C00204A52 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = A54D97DB217E5CED0072681A /* Assets.xcassets */; }; A54D97DA217A5FC10072681A /* CALayer+Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = A54D97D9217A5FC10072681A /* CALayer+Extensions.swift */; }; A559BB7E212B6D100055E107 /* String+Extension.swift in Sources */ = {isa = PBXBuildFile; fileRef = A559BB7D212B6D100055E107 /* String+Extension.swift */; }; - A559BB83212B7D870055E107 /* OfficeUIFabric.swift in Sources */ = {isa = PBXBuildFile; fileRef = A559BB82212B7D870055E107 /* OfficeUIFabric.swift */; }; + A559BB83212B7D870055E107 /* FluentUIFramework.swift in Sources */ = {isa = PBXBuildFile; fileRef = A559BB82212B7D870055E107 /* FluentUIFramework.swift */; }; A56CE7B622E68A7800AA77EE /* UIColor+Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = A56CE7B522E68A7800AA77EE /* UIColor+Extensions.swift */; }; A56CE7B722E68A7800AA77EE /* UIColor+Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = A56CE7B522E68A7800AA77EE /* UIColor+Extensions.swift */; }; A578C4A22321CFD6002D5C40 /* MSAvatar.swift in Sources */ = {isa = PBXBuildFile; fileRef = A578C4A12321CFD6002D5C40 /* MSAvatar.swift */; }; @@ -128,8 +128,8 @@ A5B87B04211E22B70038C37C /* MSDimmingView.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5B87B03211E22B70038C37C /* MSDimmingView.swift */; }; A5B87B06211E23650038C37C /* UIView+Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5B87B05211E23650038C37C /* UIView+Extensions.swift */; }; A5CEC15B20D980B30016922A /* FluentUI.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A5CEC15120D980B20016922A /* FluentUI.framework */; }; - A5CEC16020D980B30016922A /* OfficeUIFabricTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5CEC15F20D980B30016922A /* OfficeUIFabricTests.swift */; }; - A5CEC16220D980B30016922A /* OfficeUIFabric.h in Headers */ = {isa = PBXBuildFile; fileRef = A5CEC15420D980B20016922A /* OfficeUIFabric.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A5CEC16020D980B30016922A /* FluentUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5CEC15F20D980B30016922A /* FluentUITests.swift */; }; + A5CEC16220D980B30016922A /* FluentUI.h in Headers */ = {isa = PBXBuildFile; fileRef = A5CEC15420D980B20016922A /* FluentUI.h */; settings = {ATTRIBUTES = (Public, ); }; }; A5CEC16D20D98EE70016922A /* Colors.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5CEC16C20D98EE70016922A /* Colors.swift */; }; A5CEC16F20D98F340016922A /* Fonts.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5CEC16E20D98F340016922A /* Fonts.swift */; }; A5CEC23120E451D00016922A /* MSButton.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5CEC23020E451D00016922A /* MSButton.swift */; }; @@ -279,7 +279,7 @@ A54D97DB217E5CED0072681A /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; A559BB7D212B6D100055E107 /* String+Extension.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "String+Extension.swift"; sourceTree = ""; }; A559BB80212B6FA40055E107 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/Localizable.strings; sourceTree = ""; }; - A559BB82212B7D870055E107 /* OfficeUIFabric.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OfficeUIFabric.swift; sourceTree = ""; }; + A559BB82212B7D870055E107 /* FluentUIFramework.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FluentUIFramework.swift; sourceTree = ""; }; A56CE7B522E68A7800AA77EE /* UIColor+Extensions.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "UIColor+Extensions.swift"; sourceTree = ""; }; A578C4A12321CFD6002D5C40 /* MSAvatar.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MSAvatar.swift; sourceTree = ""; }; A589F853211BA03200471C23 /* MSLabel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MSLabel.swift; sourceTree = ""; }; @@ -298,10 +298,10 @@ A5B87B03211E22B70038C37C /* MSDimmingView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MSDimmingView.swift; sourceTree = ""; }; A5B87B05211E23650038C37C /* UIView+Extensions.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "UIView+Extensions.swift"; sourceTree = ""; }; A5CEC15120D980B20016922A /* FluentUI.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = FluentUI.framework; sourceTree = BUILT_PRODUCTS_DIR; }; - A5CEC15420D980B20016922A /* OfficeUIFabric.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = OfficeUIFabric.h; sourceTree = ""; }; + A5CEC15420D980B20016922A /* FluentUI.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = FluentUI.h; sourceTree = ""; }; A5CEC15520D980B20016922A /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; A5CEC15A20D980B30016922A /* FluentUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = FluentUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; - A5CEC15F20D980B30016922A /* OfficeUIFabricTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OfficeUIFabricTests.swift; sourceTree = ""; }; + A5CEC15F20D980B30016922A /* FluentUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FluentUITests.swift; sourceTree = ""; }; A5CEC16120D980B30016922A /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; A5CEC16C20D98EE70016922A /* Colors.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Colors.swift; sourceTree = ""; }; A5CEC16E20D98F340016922A /* Fonts.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Fonts.swift; sourceTree = ""; }; @@ -612,7 +612,7 @@ isa = PBXGroup; children = ( FD053A342224CA33009B6378 /* MSDatePickerControllerTests.swift */, - A5CEC15F20D980B30016922A /* OfficeUIFabricTests.swift */, + A5CEC15F20D980B30016922A /* FluentUITests.swift */, A5CEC16120D980B30016922A /* Info.plist */, ); path = FluentUI.Tests; @@ -628,7 +628,7 @@ FDF41ED82141A02200EC527C /* MSCalendarConfiguration.swift */, FD777528219E3F6C00033D58 /* MSDayOfMonth.swift */, FDA1AF8E21484A26001AE720 /* Obscurable.swift */, - A559BB82212B7D870055E107 /* OfficeUIFabric.swift */, + A559BB82212B7D870055E107 /* FluentUIFramework.swift */, FD41C8C022DD48E60086F899 /* Operators.swift */, ); path = Core; @@ -678,7 +678,7 @@ isa = PBXGroup; children = ( A5CEC15520D980B20016922A /* Info.plist */, - A5CEC15420D980B20016922A /* OfficeUIFabric.h */, + A5CEC15420D980B20016922A /* FluentUI.h */, ); name = Configuration; sourceTree = ""; @@ -892,7 +892,7 @@ isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( - A5CEC16220D980B30016922A /* OfficeUIFabric.h in Headers */, + A5CEC16220D980B30016922A /* FluentUI.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -1145,7 +1145,7 @@ 8FD0118B228A82A600D25925 /* MSCalendarConfiguration.swift in Sources */, 8FD0118C228A82A600D25925 /* MSDayOfMonth.swift in Sources */, 8FD0118D228A82A600D25925 /* Obscurable.swift in Sources */, - 8FD0118E228A82A600D25925 /* OfficeUIFabric.swift in Sources */, + 8FD0118E228A82A600D25925 /* FluentUIFramework.swift in Sources */, 8FD0118F228A82A600D25925 /* MSDateTimePicker.swift in Sources */, FD41C88922DD13230086F899 /* MSShyHeaderView.swift in Sources */, 8FD01190228A82A600D25925 /* DateTimePicker.swift in Sources */, @@ -1218,7 +1218,7 @@ B46D3F91215056940029772C /* CharacterSet+Extension.swift in Sources */, A5961FA3218A25D100E2A506 /* MSPopupMenuItemCell.swift in Sources */, FD599D0221348439008845EE /* MSCalendarView.swift in Sources */, - A559BB83212B7D870055E107 /* OfficeUIFabric.swift in Sources */, + A559BB83212B7D870055E107 /* FluentUIFramework.swift in Sources */, 1168630622E131CF0088B302 /* MSTabBarView.swift in Sources */, FD599D082134AB0E008845EE /* MSCalendarViewWeekdayHeadingView.swift in Sources */, FDFB8AF321361C9D0046850A /* MSCalendarViewDayMonthYearCell.swift in Sources */, @@ -1338,7 +1338,7 @@ isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( - A5CEC16020D980B30016922A /* OfficeUIFabricTests.swift in Sources */, + A5CEC16020D980B30016922A /* FluentUITests.swift in Sources */, FD053A352224CA33009B6378 /* MSDatePickerControllerTests.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; diff --git a/ios/FluentUI/Core/Colors.swift b/ios/FluentUI/Core/Colors.swift index 3ead7f3b47..da526f9159 100644 --- a/ios/FluentUI/Core/Colors.swift +++ b/ios/FluentUI/Core/Colors.swift @@ -68,7 +68,7 @@ public final class MSColors: NSObject { case warningShade30 public var color: UIColor { - if let fluentColor = UIColor(named: "FluentColors/" + self.name, in: OfficeUIFabricFramework.resourceBundle, compatibleWith: nil) { + if let fluentColor = UIColor(named: "FluentColors/" + self.name, in: FluentUIFramework.resourceBundle, compatibleWith: nil) { return fluentColor } else { preconditionFailure("invalid fluent color") diff --git a/ios/FluentUI/Core/OfficeUIFabric.swift b/ios/FluentUI/Core/FluentUIFramework.swift similarity index 96% rename from ios/FluentUI/Core/OfficeUIFabric.swift rename to ios/FluentUI/Core/FluentUIFramework.swift index c0ce88492c..3a8710b191 100644 --- a/ios/FluentUI/Core/OfficeUIFabric.swift +++ b/ios/FluentUI/Core/FluentUIFramework.swift @@ -5,11 +5,11 @@ import UIKit -public class OfficeUIFabricFramework: NSObject { +public class FluentUIFramework: NSObject { @objc public static var bundle: Bundle { return Bundle(for: self) } @objc public static let resourceBundle: Bundle = { guard let url = bundle.resourceURL?.appendingPathComponent("FluentUIResources-ios.bundle", isDirectory: true), let bundle = Bundle(url: url) else { - preconditionFailure("OfficeUIFabric: resource bundle is not found") + preconditionFailure("FluentUI resource bundle is not found") } return bundle }() diff --git a/ios/FluentUI/Extensions/String+Extension.swift b/ios/FluentUI/Extensions/String+Extension.swift index 488a2588e0..1ffdaffc8b 100644 --- a/ios/FluentUI/Extensions/String+Extension.swift +++ b/ios/FluentUI/Extensions/String+Extension.swift @@ -7,7 +7,7 @@ import UIKit extension String { internal var localized: String { - return NSLocalizedString(self, bundle: OfficeUIFabricFramework.resourceBundle, comment: "") + return NSLocalizedString(self, bundle: FluentUIFramework.resourceBundle, comment: "") } func formatted(with args: CVarArg...) -> String { diff --git a/ios/FluentUI/Extensions/UIImage+Extensions.swift b/ios/FluentUI/Extensions/UIImage+Extensions.swift index 7658c317c3..59e5a2c00f 100644 --- a/ios/FluentUI/Extensions/UIImage+Extensions.swift +++ b/ios/FluentUI/Extensions/UIImage+Extensions.swift @@ -7,7 +7,7 @@ import UIKit extension UIImage { class func staticImageNamed(_ name: String) -> UIImage? { - guard let image = UIImage(named: name, in: OfficeUIFabricFramework.resourceBundle, compatibleWith: nil) else { + guard let image = UIImage(named: name, in: FluentUIFramework.resourceBundle, compatibleWith: nil) else { preconditionFailure("Missing image asset with name: \(name)") } return image diff --git a/ios/FluentUI/FluentUI.h b/ios/FluentUI/FluentUI.h new file mode 100644 index 0000000000..5dbe862a1b --- /dev/null +++ b/ios/FluentUI/FluentUI.h @@ -0,0 +1,9 @@ +// +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// + +#import +// In this header, you should import all the public headers of your framework using statements like #import + + diff --git a/ios/FluentUI/Navigation/Views/MSLargeTitleView.swift b/ios/FluentUI/Navigation/Views/MSLargeTitleView.swift index f5c4a62c0c..1e6cc37dbb 100644 --- a/ios/FluentUI/Navigation/Views/MSLargeTitleView.swift +++ b/ios/FluentUI/Navigation/Views/MSLargeTitleView.swift @@ -345,7 +345,7 @@ class MSLargeTitleView: UIView { // MARK: - Notification.Name Declarations extension NSNotification.Name { - static let accessoryExpansionRequested = Notification.Name("microsoft.officeUIFabric.accessoryExpansionRequested") + static let accessoryExpansionRequested = Notification.Name("microsoft.fluentui.accessoryExpansionRequested") } // MARK: - ProfileView diff --git a/ios/FluentUI/OfficeUIFabric.h b/ios/FluentUI/OfficeUIFabric.h deleted file mode 100644 index a99eb81555..0000000000 --- a/ios/FluentUI/OfficeUIFabric.h +++ /dev/null @@ -1,16 +0,0 @@ -// -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. -// - -#import - -//! Project version number for OfficeUIFabric. -FOUNDATION_EXPORT double OfficeUIFabricVersionNumber; - -//! Project version string for OfficeUIFabric. -FOUNDATION_EXPORT const unsigned char OfficeUIFabricVersionString[]; - -// In this header, you should import all the public headers of your framework using statements like #import - - diff --git a/ios/FluentUI/Presenters/MSCardPresenterNavigationController.swift b/ios/FluentUI/Presenters/MSCardPresenterNavigationController.swift index 4f7f8bdb6c..229e030782 100644 --- a/ios/FluentUI/Presenters/MSCardPresenterNavigationController.swift +++ b/ios/FluentUI/Presenters/MSCardPresenterNavigationController.swift @@ -8,7 +8,7 @@ import UIKit class MSCardPresenterNavigationController: UINavigationController, MSCardPresentable { override func viewDidLoad() { super.viewDidLoad() - OfficeUIFabricFramework.initializeUINavigationBarAppearance(navigationBar) + FluentUIFramework.initializeUINavigationBarAppearance(navigationBar) } func idealSize() -> CGSize { diff --git a/ios/FluentUI/Table View/MSBooleanCell.swift b/ios/FluentUI/Table View/MSBooleanCell.swift index 38b1768411..aff9f68709 100644 --- a/ios/FluentUI/Table View/MSBooleanCell.swift +++ b/ios/FluentUI/Table View/MSBooleanCell.swift @@ -26,7 +26,7 @@ open class MSBooleanCell: MSTableViewCell { private lazy var `switch`: UISwitch = { let `switch` = UISwitch() - OfficeUIFabricFramework.initializeUISwitchAppearance(`switch`) + FluentUIFramework.initializeUISwitchAppearance(`switch`) `switch`.addTarget(self, action: #selector(handleOnSwitchValueChanged), for: .valueChanged) return `switch` }()