Merge branch 'develop' of https://gitlab.verizon.com/BPHV_MIPS/vds_ios_sample into feature/Table
This commit is contained in:
commit
3d7d62cebf
@ -696,7 +696,7 @@
|
|||||||
CODE_SIGN_IDENTITY = "Apple Development";
|
CODE_SIGN_IDENTITY = "Apple Development";
|
||||||
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
|
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
|
||||||
CODE_SIGN_STYLE = Manual;
|
CODE_SIGN_STYLE = Manual;
|
||||||
CURRENT_PROJECT_VERSION = 59;
|
CURRENT_PROJECT_VERSION = 60;
|
||||||
DEVELOPMENT_TEAM = "";
|
DEVELOPMENT_TEAM = "";
|
||||||
"DEVELOPMENT_TEAM[sdk=iphoneos*]" = FCMA4QKS77;
|
"DEVELOPMENT_TEAM[sdk=iphoneos*]" = FCMA4QKS77;
|
||||||
GENERATE_INFOPLIST_FILE = YES;
|
GENERATE_INFOPLIST_FILE = YES;
|
||||||
@ -731,7 +731,7 @@
|
|||||||
CODE_SIGN_IDENTITY = "Apple Development";
|
CODE_SIGN_IDENTITY = "Apple Development";
|
||||||
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
|
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
|
||||||
CODE_SIGN_STYLE = Manual;
|
CODE_SIGN_STYLE = Manual;
|
||||||
CURRENT_PROJECT_VERSION = 59;
|
CURRENT_PROJECT_VERSION = 60;
|
||||||
DEVELOPMENT_TEAM = "";
|
DEVELOPMENT_TEAM = "";
|
||||||
"DEVELOPMENT_TEAM[sdk=iphoneos*]" = FCMA4QKS77;
|
"DEVELOPMENT_TEAM[sdk=iphoneos*]" = FCMA4QKS77;
|
||||||
GENERATE_INFOPLIST_FILE = YES;
|
GENERATE_INFOPLIST_FILE = YES;
|
||||||
|
|||||||
@ -261,6 +261,21 @@ public class BaseViewController<Component: UIView>: UIViewController, Initable ,
|
|||||||
loadCustomRotors()
|
loadCustomRotors()
|
||||||
UIAccessibility.post(notification: .screenChanged, argument: component)
|
UIAccessibility.post(notification: .screenChanged, argument: component)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if component.canBecomeFirstResponder {
|
||||||
|
let tapGesture = UITapGestureRecognizer(target: self, action: #selector(dismissKeyboard))
|
||||||
|
tapGesture.cancelsTouchesInView = false // This allows the tap to pass through to other views.
|
||||||
|
view.addGestureRecognizer(tapGesture)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@objc func dismissKeyboard(_ sender: UITapGestureRecognizer) {
|
||||||
|
let location = sender.location(in: self.view)
|
||||||
|
|
||||||
|
// Check if the touch is outside the textView
|
||||||
|
if !component.frame.contains(location) {
|
||||||
|
component.resignFirstResponder()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func isViewHiddenByKeyboard(view: UIView, keyboardFrame: CGRect) -> Bool {
|
func isViewHiddenByKeyboard(view: UIView, keyboardFrame: CGRect) -> Bool {
|
||||||
|
|||||||
@ -90,3 +90,19 @@ class BreadcrumbsViewController: BaseViewController<Breadcrumbs> {
|
|||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
extension BreadcrumbsViewController: ComponentSampleable {
|
||||||
|
static func makeSample() -> ComponentSample {
|
||||||
|
let component = Self.makeComponent()
|
||||||
|
component.breadcrumbModels = [
|
||||||
|
.init(text: "Home"),
|
||||||
|
.init(text: "Support", enabeled: false),
|
||||||
|
.init(text: "Service & Apps"),
|
||||||
|
.init(text: "My Verizon"),
|
||||||
|
.init(text: "Bill"),
|
||||||
|
.init(text: "Mobile Billing & Payments"),
|
||||||
|
.init(text: "Billing statement FAQs", selected: true)
|
||||||
|
]
|
||||||
|
return ComponentSample(component: component)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@ -181,6 +181,7 @@ class ButtonIconViewController: BaseViewController<ButtonIcon> {
|
|||||||
let name = Icon.Name.addToFavorite
|
let name = Icon.Name.addToFavorite
|
||||||
|
|
||||||
component.iconName = name
|
component.iconName = name
|
||||||
|
component.onChange = { c in print("changed: \(c.isSelected)") }
|
||||||
//setup UI
|
//setup UI
|
||||||
surfacePickerSelectorView.text = component.surface.rawValue
|
surfacePickerSelectorView.text = component.surface.rawValue
|
||||||
surfaceTypePickerSelectorView.text = component.surfaceType.rawValue
|
surfaceTypePickerSelectorView.text = component.surfaceType.rawValue
|
||||||
@ -261,6 +262,9 @@ extension ButtonIconViewController: ComponentSampleable {
|
|||||||
static func makeSample() -> ComponentSample {
|
static func makeSample() -> ComponentSample {
|
||||||
let component = Self.makeComponent()
|
let component = Self.makeComponent()
|
||||||
component.iconName = .addToFavorite
|
component.iconName = .addToFavorite
|
||||||
|
component.selectedIconName = .addedToFavorite
|
||||||
|
component.selectable = true
|
||||||
|
component.onChange = { c in print("changed: \(c.isSelected)") }
|
||||||
component.size = .large
|
component.size = .large
|
||||||
return ComponentSample(component: component, trailingPinningType: .lessThanOrEqual)
|
return ComponentSample(component: component, trailingPinningType: .lessThanOrEqual)
|
||||||
}
|
}
|
||||||
|
|||||||
@ -119,3 +119,12 @@ class CarouselScrollbarViewConttroller: BaseViewController<CarouselScrollbar> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
extension CarouselScrollbarViewConttroller: ComponentSampleable {
|
||||||
|
static func makeSample() -> ComponentSample {
|
||||||
|
let component = Self.makeComponent()
|
||||||
|
component.numberOfSlides = 4
|
||||||
|
return ComponentSample(component: component)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@ -431,3 +431,29 @@ public class ShadowView: View {
|
|||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
extension ViewProtocol where Self: UIView {
|
||||||
|
private func createShadowLayer() -> CALayer {
|
||||||
|
let shadowLayer = CALayer()
|
||||||
|
shadowLayer.backgroundColor = UIColor.clear.cgColor
|
||||||
|
shadowLayer.frame = bounds
|
||||||
|
return shadowLayer
|
||||||
|
}
|
||||||
|
|
||||||
|
func addCustomShadow(config: DropShadowConfiguration) {
|
||||||
|
let shadowLayer = createShadowLayer()
|
||||||
|
// shadowLayer.shadowColor = config.shadowColorConfiguration.getColor(self).cgColor
|
||||||
|
// shadowLayer.shadowOpacity = config.shadowOpacityConfiguration.value(for: self)
|
||||||
|
// shadowLayer.shadowOffset = offset
|
||||||
|
// shadowLayer.shadowRadius = radius
|
||||||
|
layer.insertSublayer(shadowLayer, at: 0)
|
||||||
|
}
|
||||||
|
|
||||||
|
func removeAllCustomShadows() {
|
||||||
|
layer.sublayers?.forEach { sublayer in
|
||||||
|
if sublayer.shadowOpacity > 0 && sublayer.backgroundColor == UIColor.clear.cgColor {
|
||||||
|
sublayer.removeFromSuperlayer()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@ -186,3 +186,22 @@ class DropdownSelectViewController: BaseViewController<DropdownSelect> {
|
|||||||
content: content) : nil
|
content: content) : nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
extension DropdownSelectViewController: ComponentSampleable {
|
||||||
|
static func makeSample() -> ComponentSample {
|
||||||
|
let component = Self.makeComponent()
|
||||||
|
component.labelText = "Street Address"
|
||||||
|
component.helperText = "For example: 123 Verizon St"
|
||||||
|
component.errorText = "Enter a valid address."
|
||||||
|
component.tooltipModel = .init(title: "Check the formatting of your address", content:"House/Building number then street name")
|
||||||
|
component.options = [
|
||||||
|
.init(text: "Alabama"),
|
||||||
|
.init(text: "Alaska"),
|
||||||
|
.init(text: "Arizona"),
|
||||||
|
.init(text: "Arkansas")
|
||||||
|
]
|
||||||
|
return ComponentSample(component: component)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -46,3 +46,11 @@ final class PaginationViewController: BaseViewController<Pagination> {
|
|||||||
}.store(in: &subscribers)
|
}.store(in: &subscribers)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
extension PaginationViewController: ComponentSampleable {
|
||||||
|
static func makeSample() -> ComponentSample {
|
||||||
|
let component = Self.makeComponent()
|
||||||
|
component.total = 10
|
||||||
|
return ComponentSample(component: component)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@ -99,6 +99,8 @@ class TileContainerViewController: BaseViewController<TileContainer> {
|
|||||||
addContentTopView(view: .makeWrapper(for: component))
|
addContentTopView(view: .makeWrapper(for: component))
|
||||||
component.width = 150
|
component.width = 150
|
||||||
component.color = .secondary
|
component.color = .secondary
|
||||||
|
component.accessibilityLabel = "Tile Container"
|
||||||
|
component.addContentView(Label().with { $0.text = "Testing Label" })
|
||||||
setupPicker()
|
setupPicker()
|
||||||
setupModel()
|
setupModel()
|
||||||
}
|
}
|
||||||
@ -165,7 +167,7 @@ class TileContainerViewController: BaseViewController<TileContainer> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
showDropShadowSwitch.onChange = { [weak self] sender in
|
showDropShadowSwitch.onChange = { [weak self] sender in
|
||||||
self?.component.showDropShadows = sender.isOn
|
self?.component.showDropShadow = sender.isOn
|
||||||
}
|
}
|
||||||
|
|
||||||
heightTextField
|
heightTextField
|
||||||
|
|||||||
@ -291,7 +291,7 @@ class TileletViewController: BaseViewController<Tilelet> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
showDropShadowSwitch.onChange = { [weak self] sender in
|
showDropShadowSwitch.onChange = { [weak self] sender in
|
||||||
self?.component.showDropShadows = sender.isOn
|
self?.component.showDropShadow = sender.isOn
|
||||||
}
|
}
|
||||||
|
|
||||||
imageFallbackColorPickerSelectorView.onPickerDidSelect = { [weak self] item in
|
imageFallbackColorPickerSelectorView.onPickerDidSelect = { [weak self] item in
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user