Managed Settings

RSS for tag

Set restrictions for certain settings, such as locking accounts in place, preventing password modification, filtering web traffic, and shielding apps.

Posts under Managed Settings tag

108 Posts
Sort by:
Post not yet marked as solved
8 Replies
1.2k Views
Hello Apple Developer Community, We're experiencing a critical issue with the Screen Time frameworks, and it's affecting one of our users severely. I'm hoping someone here can provide guidance or a potential solution. Details: Our app offers a feature using the ManagedSettings shield that lets users block all apps based on a set schedule. After the scheduled block ends, the apps are expected to become accessible again. In one case, a user reported that the apps did not unblock after the schedule ended. Upon trying to manually end the session from within our app, the app only displays a blank white screen. The user attempted to disable Screen Time access for our app via the iOS settings, but the apps remained blocked. Even after completely disabling Screen Time from the settings or restarting the phone, the apps stayed blocked. Interestingly, I attempted to replicate the issue on my end by toggling Screen Time settings and restarting, but everything worked as expected and I could not reproduce the problem. This issue, though seemingly isolated, has rendered a user's phone virtually unusable, and highlights a potential high-impact bug within the Screen Time framework. It feels necessary for there to be a "master off-switch" or a fail-safe mechanism in these scenarios. Any insights, solutions, or workarounds would be deeply appreciated. It's crucial for us to support our user and resolve this promptly. Thank you in advance!
Posted Last updated
.
Post not yet marked as solved
1 Replies
608 Views
We have an app that uses the Screen Time APIs to block certain apps set by the user on a schedule: We use ManagedSettings to shield selected apps We use DeviceActivityMonitor to shield the apps automatically on a schedule set by the user. The shielding starts during the intervalDidStart callback function and ends during the intervalDidEnd callback function We are getting reports from the majority of our iOS 17 users that the app blocking schedules no longer work on iOS 17. We have tested this on our own iOS 17 devices and reproduced the behavior. But the feature still works consistently on iOS 16 devices. The app is still built using Xcode 14 instead of Xcode 15 due to another issue - the DeviceActivityReport is blank for all iOS 16 users when built in Xcode 15 (link to issue on the developer forums: https://developer.apple.com/forums/thread/735915). When testing with Xcode 15 builds, the bug appears to improve - however it still occurs intermittently. Are there any other mechanisms to run tasks on repeating schedules? For this specific feature, we don't need to eventDidReachThreshold callbacks, which is the main purpose of DeviceActivityMonitor. So we really don't need any Device Activity integration at all, just setting and disabling ManagedSettings shields at certain times. Would love if anyone could suggest and alternative to DeviceActivityMonitor.
Posted Last updated
.
Post not yet marked as solved
1 Replies
708 Views
I use App Groups to share UserDefaults data between my host app and DeviceActivityMonitor extension. On iOS 17, it appears that reading @AppStorage variables are causing my DeviceActivityMonitor extension callback functions to crash. Weirdly, writing values is okay. I see this in the extension logs: Couldn't read values in CFPrefsPlistSource<0x10fe251d0> (Domain: GROUP_NAME, User: kCFPreferencesAnyUser, ByHost: Yes, Container: (null), Contents Need Refresh: Yes): Using kCFPreferencesAnyUser with a container is only allowed for System Containers, detaching from cfprefsd However, through searching this log message on the internet and the fact that it also appears in my host app logs without crashing, this seems to be a warning - possibly indicating an issue but also a possible red herring. But the fact remains that when I don't read UserDefaults values or variables decorated with @AppStorage in the DeviceActivityMonitor extension, everything works fine. Are UserDefaults, and specifically @AppStorage decorators supported in the DeviceActivityMonitor extension?
Posted Last updated
.
Post not yet marked as solved
0 Replies
427 Views
I have posted this already in Feedback Assistant back in September with detailed steps to reproduce and have not heard back. Posting a brief overview here in hopes that Apple acknowledges and addresses this issue that is still present in recent Sonoma betas. This is preventing our organization from updating to Sonoma, however the Apple maximum update deferral timeline of 90 days is running out at Christmas. The Switch User option is missing from the Lock Screen on macOS Sonoma if only one person has ever signed in for an enterprise device with an MDM pushed (and verified) configuration profile which allows user switching and network users to sign in to the device. It only shows users who are not hidden and have a home folder. This locks out all users without a hard reboot if nobody else exists on the device, or the user can do something that is very unintuitive if there are 2 or more users who have signed in. They can click any other user than the one who was logged in when the lockscreen process started, and that will let them erase the username of the user they clicked and log in themselves. What is missing is "Other..." or "Switch User", which were on the Lock Screen for pervious versions of macOS. The login screen works just fine, it's the lock screen that's now ignoring configuration profiles or just doesn't have the same settings as the loginwindow process.
Posted
by blakezsmu.
Last updated
.
Post not yet marked as solved
0 Replies
402 Views
Any way that I try requesting authorization for family controls is incredibly inconsistent. The line of code that hangs is **let center = AuthorizationCenter.shared ** I've looked at other posts and I saw someone recommended declaring let center = AuthorizationCenter.shared outside the main thread and somehow get the status on the main thread. I've tried that approach with no success. I've scoured GitHub to see how other people approach the request but it's all pretty similar. The following code sometimes works great for a few minutes and then I rebuild and run and it hangs on AuthorizationCenter.shared.requestAuthorization(for: FamilyControlsMember.individual). Would love any suggestions!!! .onAppear { Task { do { print("try requestAuthorization") try await AuthorizationCenter.shared.requestAuthorization(for: FamilyControlsMember.individual) print("requestAuthorization success") switch AuthorizationCenter.shared.authorizationStatus { case .notDetermined: print("not determined") case .denied: print("denied") case .approved: print("approved") @unknown default: break } } catch { print("Error requestAuthorization: ", error) } } }
Posted
by adison25.
Last updated
.
Post not yet marked as solved
0 Replies
280 Views
I have gained the PassKit access, but don't know how to configure com. Apple. Developer. PassKit. Pass the presentation - suppression the permissions. Who can tell us the detailed process, which Capabilities should be configured in the App ID?
Posted
by CYRainy.
Last updated
.
Post not yet marked as solved
0 Replies
408 Views
DL;DR: Sometimes the API fails to unblock the app and leaves an hourglass shield on the restricted apps, which is not set by us. Even worse, if we remove authorization of our app from Settings, the restricted apps remain locked until we restart the phone or re-run our app from Xcode. Our app monitors the usage of selected apps from the current time until the reset time at 4:00 a.m. When the given threshold is reached, the selected apps are shielded. After the user taps the close button on the shield view, we attempt to remove the shield, set up a new threshold monitoring and close the app. The issue is that: sometimes the shield removal fails, and after the app closes itself, it remains shielded, and displays an hourglass shield view that was never in our shield configuration. Additionally, regardless of what we do-removing the shielding from our apps or removing the authorization of our app from Settings, the restricted apps remain shielded until we restart the phone or re-run our app from Xcode. Code I use for un-shielding: warningUsageStore.clearAllSettings() Code I use for scheduling the threshold: var warningMinute = userDefaults.integer(forKey: .warningMinute) if warningMinute <= 0 { warningMinute = 5 } let selection = familyActivitySelection() let now = Date.now let start = Calendar.current.dateComponents([.hour, .minute, .second], from: now) var end = AppConfig.resetEndTime // use twenty minutes later as the end time if the before reset time is too near e.g. warning start at 3:55 but reset time is 4:00 if let endDate = Calendar.current.nextDate(after: now, matching: end, matchingPolicy: .nextTime), endDate.timeIntervalSince(now) <= 15*60 { end = Calendar.current.dateComponents([.hour, .minute, .second], from: now.addingTimeInterval(20*60)) } // add inidividual event according to the hash value to dintinguish between apps. var events = [DeviceActivityEvent.Name : DeviceActivityEvent]() for application in selection.applications where application.token != nil { events[.init(application.hashValue.description)] = .init(applications: [application.token!], threshold: .init(minute: warningMinute)) } for category in selection.categories where category.token != nil { events[.init(category.hashValue.description)] = .init(categories: [category.token!], threshold: .init(minute: warningMinute)) } for webDomain in selection.webDomains where webDomain.token != nil { events[.init(webDomain.hashValue.description)] = .init(webDomains: [webDomain.token!], threshold: .init(minute: warningMinute)) } try deviceActivityCenter.startMonitoring(.usageWarning, during: .init(intervalStart: start, intervalEnd: end, repeats: false), events: events) The issue happens on my iPhone11 iOS17.1.2 Any insight would be much appreciated. Thank you!
Posted Last updated
.
Post not yet marked as solved
1 Replies
560 Views
Hello, I'm currently experiencing an issue with the DeviceActivityMonitor extension in my code, specifically with the eventDidReachThreshold callback. I'm hoping to get some insights into why this problem occurs and how to resolve it. Problem: Issue 1: The eventDidReachThreshold callback is not triggering as expected. It appears that the callback is not being invoked when the threshold is reached. Issue 2: After a few seconds, the eventDidReachThreshold callback starts to trigger multiple times. This unexpected behavior is causing problems in my code, as it results in incorrect actions being taken. Issue 3: There are instances where the eventDidReachThreshold callback provides an incorrect event name. iOS version: iOS16.7.2 and iOS17.1.1 Here is my code to start the monitoring: func startMonitoring() { var startTime : DateComponents = DateComponents(hour: 0, minute: 0) let endTime : DateComponents = DateComponents(hour: 23, minute: 59) /// Creates the schedule for the activity, specifying the start and end times, and setting it to repeat. let schedule = DeviceActivitySchedule(intervalStart: startTime, intervalEnd: endTime, repeats: true, warningTime: nil) /// Defines the event that should trigger the encouragement. let event = DeviceActivityEvent(applications: socialActivitySelection.applicationTokens, categories: socialActivitySelection.categoryTokens, webDomains: socialActivitySelection.webDomainTokens, threshold: DateComponents(minute: 2)) let events: [DeviceActivityEvent.Name: DeviceActivityEvent] = [.socialScreenTimeEvent : event] do { activityCenter.stopMonitoring([.socialScreenTime]) /// Tries to start monitoring the activity using the specified schedule and events. try activityCenter.startMonitoring(.socialScreenTime, during: schedule, events: events) } catch { /// Prints an error message if the activity could not be started. print("Could not start monitoring: \(error)") } } In addition, I should mention that, with each iteration through the eventDidReachThreshold callback, I increment the threshold by 2 minutes and restart the monitoring. If there are any known workarounds or potential solutions, please share them. Thank you.
Posted
by walid12.
Last updated
.
Post not yet marked as solved
3 Replies
1.5k Views
I created a ShieldConfigurationExtension in Xcode 14.3 with File > New > Target > ShieldConfigurationExtension. This created the extension with all the necessary Info.plist values (correct NSExtensionPrincipalClass, etc.), with the extension included in embedded content in the host app target. No matter what I try, the extension is not getting invoked when I shield applications from my host app. The custom UI does not show as the shield, and looking at the debugger, an extension process is never invoked. I am shielding categories like this: let managedSettings = ManagedSettingsStore() ... managedSettings.shield.applicationCategories = .all() And my extension code overrides all the ShieldConfigurationDataSource functions. class ShieldConfigurationExtension: ShieldConfigurationDataSource { override func configuration(shielding application: Application) -> ShieldConfiguration { return ShieldConfiguration( backgroundBlurStyle: UIBlurEffect.Style.systemThickMaterial, backgroundColor: UIColor.white, icon: UIImage(systemName: "stopwatch"), title: ShieldConfiguration.Label(text: "You are in a Present Session", color: .yellow) ) } override func configuration(shielding application: Application, in category: ActivityCategory) -> ShieldConfiguration { return ShieldConfiguration( backgroundBlurStyle: UIBlurEffect.Style.systemThickMaterial, backgroundColor: UIColor.white, icon: UIImage(systemName: "stopwatch"), title: ShieldConfiguration.Label(text: "You are in a Present Session", color: .yellow) ) } override func configuration(shielding webDomain: WebDomain) -> ShieldConfiguration { return ShieldConfiguration( backgroundBlurStyle: UIBlurEffect.Style.systemThickMaterial, backgroundColor: UIColor.white, icon: UIImage(systemName: "stopwatch"), title: ShieldConfiguration.Label(text: "You are in a Present Session", color: .yellow) ) } override func configuration(shielding webDomain: WebDomain, in category: ActivityCategory) -> ShieldConfiguration { return ShieldConfiguration( backgroundBlurStyle: UIBlurEffect.Style.systemThickMaterial, backgroundColor: UIColor.white, icon: UIImage(systemName: "stopwatch"), title: ShieldConfiguration.Label(text: "You are in a Present Session", color: .yellow) ) } } What am I missing?
Posted Last updated
.
Post not yet marked as solved
0 Replies
440 Views
My app uses DeviceActivitySchedule to let users set schedules to block certain apps. I naturally want to understand how my users are using the feature, so I capture analytics events using Segment. Ever since the release of iOS 17.1, analytics events from DeviceActivityMonitor have stopped firing. I believe this is due to the fact that the app extension that DeviceActivityMonitor runs in does not support asynchronous network requests. (However, I'm not sure why the analytics were working correctly with iOS 16). What is the best way to capture analytics inside the DeviceActivityMonitor app extension in iOS 17?
Posted Last updated
.
Post not yet marked as solved
1 Replies
371 Views
Are there published limits for how many concurrent ManagedSettingsStore our apps can have going at once? More importantly, is there a way for our app to retrieve all the ManagedSettingStore.Name that are already applied by our app? (Not system wide, just our app). DeviceActivityCenter().activities fetches all the DeviceActivityName that are being monitored actively. Is there something similar?
Posted
by heykurt.
Last updated
.
Post not yet marked as solved
3 Replies
1.1k Views
Hello! I believe there is a bug: ShieldConfigurationDataSource extension does not update when the app to be blocked is already open and the ManagedSettingsStore.shield.applications is set to the app that is already open. The shield comes up but has a stale ShieldConfiguration not reflecting the current state of the app is used. I've been able to replicate the issue in an independent app "OffScreen". If you start a blocking time range from 10:00-10:15, it will say "No Twitter until 10:15" and then open Twitter at 10:15. If there is another blocking time range from 10:16-10:31, the app will be open until 10:16 when the shield will reactivate and it will still say "No Twitter until 10:15" when is should say "No Twitter until 10:31". thanks!
Posted
by dev0618.
Last updated
.
Post not yet marked as solved
1 Replies
531 Views
Having trouble in signing in to iCloud when a managed supervised iPhone is restricted with few apps using “allowListedAppBundleIDs” restrictions key. Only iPhone has this trouble, this issue is not reproducible in iPad. Even after entering the Apple ID and password, the account seems to be not logged in. Have attached screenshots for reference. Tested device iOS Version : 17.1 Kindly explain this behaviour. Feedback ID : #FB13318247 - Sysdiagnose logs attached here.
Posted Last updated
.
Post not yet marked as solved
5 Replies
1.3k Views
Hi, I'm having trouble understanding what is the correct DateComponents format for the DeviceActivityCenter.startMonitoring to work as expected. Here's how it behaves with my setup: The schedule interval is set for 15 minutes (the minimum). On intervalDidStart I set the shields shield.applicationCategories = .all(except: exclCat) shield.webDomainCategories = .all(except: exclWeb) On intervalDidEnd I clear the settings shield.applicationCategories = nil shield.webDomainCategories = nil Different behavior with different DeviceActivitySchedule intervals. In the below examples I'll refer to hour, minute and second components as time components, and the calendar, timeZone, year, month, day, hour, minute and second components as date and time components. Also, with all combinations below no errors are thrown when calling the startMonitoring method. A. ❌ The start interval has time components, while the end interval has date and time components: The intervalDidStart is not triggered. DeviceActivitySchedule(schedule: <USDeviceActivitySchedule: 0x28354a5e0> IntervalStart: <NSDateComponents: 0x2839c7f40> { Hour: 9 Minute: 24 Second: 55 IntervalEnd: <NSDateComponents: 0x2839c7f70> { Calendar: <CFCalendar 0x2818f9090 [0x1e4fb1d10]>{identifier = 'gregorian'} TimeZone: Asia/Manila (GMT+8) offset 28800 Calendar Year: 2023 Month: 5 Leap Month: 0 Day: 15 Hour: 9 Minute: 39 Second: 55 Repeats: 0 WarningTime: (null)) B. ❌ The start interval has date and time components, while the end interval has time components: Here, the opposite of the above example happens — the intervalDidStart is triggered, but the intervalDidEnd is not. C. ❌ Both intervals have time components: The intervalDidStart is not triggered. D. ✅ Only hour, minute, and second components for both start and end intervals: Callbacks are called as expected. DeviceActivitySchedule(schedule: <USDeviceActivitySchedule: 0x282e80450> IntervalStart: <NSDateComponents: 0x2822f39f0> { Hour: 9 Minute: 12 Second: 15 IntervalEnd: <NSDateComponents: 0x2822f3a00> { Hour: 9 Minute: 27 Second: 15 Repeats: 0 WarningTime: (null)) So it seems that the correct and working version is with the time components only. However, from the documentation, the maximum schedule interval is a week. So if I need to set the schedule starting from a certain time of day A and ending in a certain time of day B, what should the DateComponents look like? Thanks for you help!
Posted Last updated
.
Post not yet marked as solved
2 Replies
361 Views
I have been unable to get ANY Apple Developer support today. The phone number I had connected to my business Apple Developer account is changed and it seems the only way that the Apple website can authenticate is by THAT number and does not even offer email as an alternative solution to login and change my phone number. Nobody at Apple Support can connect me to a single Apple Developer contact and NOBODY seems capable of solving this problem. Why pay for this developer platform if there isn't any support?
Posted
by tayco.
Last updated
.
Post not yet marked as solved
0 Replies
302 Views
My company has recently finalized a contract with another company that had 2FA enabled for one of our email accounts associated with our PlayStore developer account. Regrettably, we have lost contact with this company and now require the modification of the 2FA currently registered on their phone. How do I get in contact directly with a person from apples support?
Posted Last updated
.
Post not yet marked as solved
0 Replies
397 Views
We are making an appstore app to be opened in single app kiosk mode(App Lock Policy for a single app) . When tried to open and login , a popup which is seen when opened without kiosk mode is not opening up. Attached the screenshot of the popup screen. (not able to attach the video here) Raised Feedback id - FB13304240 AppLock Policy Payload sent to the device : <dict> <key>PayloadVersion</key> <integer>1</integer> <key>PayloadUUID</key> <string></string> <key>PayloadType</key> <string>Configuration</string> <key>PayloadOrganization</key> <string>fhd</string> <key>PayloadIdentifier</key> <string>sample_id</string> <key>PayloadDisplayName</key> <string>Kiosk Zenoti</string> <key>PayloadRemovalDisallowed</key> <true/> <key>PayloadContent</key> <array> <dict> <key>PayloadVersion</key> <integer>1</integer> <key>PayloadUUID</key> <string>ad18a938-211e-4670-9be6-6f43162b6290</string> <key>PayloadType</key> <string>com.apple.app.lock</string> <key>PayloadOrganization</key> <string>MDM</string> <key>PayloadIdentifier</key> <string>a � �d18a938-211e-4670-9be6-6f43162b6290</string> <key>PayloadDisplayName</key> <string>AppLock Policy</string> <key>App</key> <dict> <key>Options</key> <dict> <key>DisableTouch</key> <false/> <key>DisableDeviceRotation</key> <false/> <key>DisableVolumeButtons</key> <false/> <key>DisableRingerSwitch</key> <false/> <key>DisableSleepWakeButton</key> <false/> <key>DisableAutoLock</key> <true/> <key>EnableVoiceOver</key> <false/> <key>EnableZoom</key> <false/> <key>EnableInvertColors</key> <false/> <key>EnableAssistiveTouch</key> <false/> <key>EnableSpeakSelection</key> <false/> <key>EnableMonoAudio</key> <false/> <key>EnableVoiceControl</key> <false/> </dict> <key>UserEnabledOptions</key> <dict> <key>VoiceOver</key> <false/> <key>Zoom</key> <false/> <key>InvertColors</ke � y> <false/> <key>AssistiveTouch</key> <false/> </dict> <key>Identifier</key> <string>com.zenoti.mpos</string> </dict> <key>Identifier</key> <string>com.zenoti.mpos</string> </dict> </array> </dict> </plist>
Posted Last updated
.
Post not yet marked as solved
4 Replies
1.6k Views
I've followed along with the Screen Time API demos (https://developer.apple.com/videos/play/wwdc2021/10123/) Also followed along with this guide, which is essentially the same: https://www.folio3.com/mobile/blog/screentime-api-ios/ I'm able to restrict access to apps/categories with the FamilyActivityPicker and FamilyActivitySelection. I can set a DeviceActivitySchedule, and then use DeviceActivityCenter to start monitoring it. I can tell that the schedule is working, because MyMonitor:intervalDidStart() does get called, and it works except for the restricting of apps/categories/webCategories. It's as if MyModel does not have any values set from within MyMonitor. I've confirmed that MyModel does have the correct FamilyActivitySelection apps etc, everywhere else in my Target, before and after the MyMonitor:intervalDidStart() gets called. MyMonitor is in a separate target called MonitorExtension, that I created using the Device Activity Monitor Extension template. But I made sure to set the Target Membership of MyModel to both my main target, and my extension target. I have set NSExtensionPrincipalClass to $(PRODUCT_MODULE_NAME).MyMonitor, as suggested. I have added MyModel.swift to the Compiled Sources in my extensions Build Phases. I have edited my apps build scheme, to make sure the extension target is also built. One more interesting thing is that debugger breakpoints and print statements do not work from within my extension. I've even tried caching a string from within MyMonitor:intervalDidStart, and tried to retrieve it afterwards in my main target, but it is nil. Still, I've confirmed that intervalDidStart was actually called by adding any removing store.application.denyAppInstallation = true, and having it work correctly. I've spent so much time on this problem, any help would be massive.. Here are the files I've referenced: import UIKit import MobileCoreServices import ManagedSettings import DeviceActivity class MyMonitor: DeviceActivityMonitor {   let store = ManagedSettingsStore()   override func intervalDidStart(for activity: DeviceActivityName) {     super.intervalDidStart(for: activity)     let model = MyModel.shared     let applications = model.selectionToDiscourage.applicationTokens     let categories = model.selectionToDiscourage.categoryTokens     let webCategories = model.selectionToDiscourage.webDomainTokens          if applications.isEmpty {      print("No applications to restrict")     } else {      store.shield.applications = applications     }          if categories.isEmpty {      print("No categories to restrict")     } else {      store.shield.applicationCategories = ShieldSettings.ActivityCategoryPolicy.specific(categories, except: Set())     }          if webCategories.isEmpty {      print("No web categories to restrict")     } else {      store.shield.webDomains = webCategories     }     store.dateAndTime.requireAutomaticDateAndTime = true     store.account.lockAccounts = true     store.passcode.lockPasscode = true     store.siri.denySiri = true     store.appStore.denyInAppPurchases = true     store.appStore.maximumRating = 200     store.appStore.requirePasswordForPurchases = true     store.media.denyExplicitContent = true     store.gameCenter.denyMultiplayerGaming = true     store.media.denyMusicService = true     store.application.denyAppInstallation = true   }   override func intervalDidEnd(for activity: DeviceActivityName) {     super.intervalDidEnd(for: activity)     store.shield.applications = nil     store.shield.applicationCategories = nil     store.shield.webDomains = nil     store.dateAndTime.requireAutomaticDateAndTime = false     store.account.lockAccounts = false     store.passcode.lockPasscode = false     store.siri.denySiri = false     store.appStore.denyInAppPurchases = false     store.appStore.maximumRating = 1000     store.appStore.requirePasswordForPurchases = false     store.media.denyExplicitContent = false     store.gameCenter.denyMultiplayerGaming = false     store.media.denyMusicService = false     store.application.denyAppInstallation = false   } } import Foundation import FamilyControls import DeviceActivity import ManagedSettings class MyModel: ObservableObject {   static let shared = MyModel()   let store = ManagedSettingsStore()   private init() {}   var selectionToDiscourage = FamilyActivitySelection() {     willSet {       let applications = newValue.applicationTokens       let categories = newValue.categoryTokens       let webCategories = newValue.webDomainTokens       store.shield.applications = applications.isEmpty ? nil : applications       store.shield.applicationCategories = ShieldSettings.ActivityCategoryPolicy.specific(categories, except: Set())       store.shield.webDomains = webCategories      }   }   func initiateMonitoring(scheduleStart: DateComponents, scheduleEnd: DateComponents) {     let schedule = DeviceActivitySchedule(intervalStart: scheduleStart, intervalEnd: scheduleEnd, repeats: true, warningTime: nil)     print(scheduleStart)     print(scheduleEnd)     let center = DeviceActivityCenter()     do {       try center.startMonitoring(.daily, during: schedule)     }     catch {       print ("Could not start monitoring \(error)")     }          store.dateAndTime.requireAutomaticDateAndTime = false     store.account.lockAccounts = false     store.passcode.lockPasscode = false     store.siri.denySiri = false     store.appStore.denyInAppPurchases = false     store.appStore.maximumRating = 1000     store.appStore.requirePasswordForPurchases = false     store.media.denyExplicitContent = false     store.gameCenter.denyMultiplayerGaming = false     store.media.denyMusicService = false     store.application.denyAppInstallation = false   } } extension DeviceActivityName {   static let daily = Self("daily") } import SwiftUI import FamilyControls struct AppPicker: View {   @StateObject var model = MyModel.shared   @State var isPresented = false       var body: some View {     Button("Select Apps to Discourage") {       isPresented = true     }     .familyActivityPicker(isPresented: $isPresented, selection: $model.selectionToDiscourage)   } }
Posted
by Drewber.
Last updated
.
Post not yet marked as solved
0 Replies
333 Views
ShieldActionDelegate called .secondaryButtonPressed with secondaryButtonLabel == nil. Step to reproduce: Make configure ShieldConfiguration with primaryButtonLabel configure only. Add some method (in my case I add unblock all) in ShieldActionDelegate by case .secondaryButtonPressed On Shield make a few taps on secondary button area see attached image handle(action: ShieldAction, for application: ApplicationToken ... for case .secondaryButtonPressed called - it's wrong, I don't have second button configured, but action is called. Added feedback: 13254523
Posted
by potlov.
Last updated
.