Search results for

calendar

1,863 results found

Post

Replies

Boosts

Views

Activity

[iOS18 22A5350a] remove to do list from calendar
I have updated my iPhone SE 2020 with the iOS18 beta, I've been doing this since iOS17. Everything is fine, until I look at my calendar. My to do list is in the calendar, I don't want that, it's a mess, I have 2 daily repetitive to do lists, and my calendar has become a mess, I already have this in the to do list. Does anyone know how I can remove this? I've already gone to setup, there's no option in the calendar, and I couldn't find it in the to do list either. Thank you in advance for your help.
1
0
526
Sep ’24
Command PhaseScriptExecution failed with a nonzero exit code
Context: I am working on a React Native project using Expo and Xcode. I’m encountering an error during the build process that I’ve been unable to resolve. I’ve tried various troubleshooting steps, but the issue persists. Environment Details: Xcode Version: (Specify your Xcode version here, e.g., Xcode 15) macOS Version: (Specify your macOS version here, e.g., macOS 14 Ventura) React Native Version: 0.74.5 Expo SDK Version: 51.0.27 Node Version: (22.6) Error Command PhaseScriptExecution failed with a nonzero exit code node_modules/react-native/scripts/react_native_pods_utils/script_phases.sh: line 34: /opt/homebrew/Cellar/node/22.5.1/bin/node: No such file or directory i have almost tried everything but still same error again and again to debug this i have used stack overflow,chat GPT,bing,Gemini AI, readit Please help me to resolve this issue My Dependencies dependencies: { @10play/tentap-editor: ^0.5.17, @expo/webpack-config: ^19.0.1, @react-native-async-storage/async-storage: 1.23.1, @react-navigation/drawe
1
0
1.3k
Aug ’24
Reply to How to add menu items to dock item when app not running
Well, it's all in the title. I want to make a URL history list available on the dock item of my macOS app. I found NSDockTilePlugin but nothing on how to implement it. Can anyone help? First off, are you sure you actually want a NSDockTilePlugin? NSDockTilePlugin is specifically how an app that ISN'T running can update it's dock icon. For example, it's how Calendar is able to show the correct date on it's icon, even when you aren't running. Unfortunately, the dock plugin API is an old loadable plugin API, NOT a modern app extension. They're not allowed in App store apps and are not something I'd recommend creating today. HOWEVER, let me go back to what you said hear: I want to make a URL history list available on the dock item of my macOS app. The key words above where how an app that ISN'T running. If your app is running, then it has full control of everything it puts in the Dock. Your app icon is controlled through NSApplication.dockTile and your windows through NSWindow.dockTile. The NSDockTile cl
Aug ’24
Reply to iOS18 Control Widget dynamic switch intent
What's a ControlWidgetTemplate? I can't find that in the Developer app. The error is because you're returning a ControlWidgetButton in a struct that says it's a ControlWidgetTemplate type. It looks like you just want to return the right 'thing' in the ControlWidget struct. Something like this: (tweak it to get it to do what you want) func chooseControlWidgetContent() -> ControlWidgetButton { if (applaunched) { return ControlWidgetButton(action: Aintent()) { Label(xxxx, systemImage: calendar) } } else { return ControlWidgetButton(action: Bintent()) { Label(xxxx, systemImage: calendar) } } } @available(iOS 18.0, *) struct ControlWidgetContent: ControlWidget { let kind: String = ControlWidgetInterface var body: some ControlWidgetConfiguration { StaticControlConfiguration( kind: kind ) { chooseControlWidgetContent() }.displayName(xxxx) } }
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Aug ’24
iOS18 Control Widget dynamic switch intent
Objective: When the app is running, directly operate the app without launching it. When the app is not started, wake up the app to perform the corresponding operation. Premise: AppIntent's openAppWhenRun can dynamically control whether the app is launched, but the variable itself cannot be changed. Therefore, the idea is to refresh the widget when the app is started or terminated, displaying different content (binding different intents) to achieve the goal. However, there are persistent issues during code implementation. struct ControlWidgetContent: ControlWidgetTemplate { var body: some ControlWidgetTemplate { if (applaunched) { return ControlWidgetButton(action: Aintent()) { Label(xxxx, systemImage: calendar) } } else { return ControlWidgetButton(action: Bintent()) { Label(xxxx, systemImage: calendar) } } } } @available(iOS 18.0, *) struct ControlWidgetContent: ControlWidget { let kind: String = ControlWidgetInterface var body: some ControlWidgetConfiguration { StaticControlConfiguration(
2
0
918
Aug ’24
Reply to Swiftdata with Date
Example: when I'm selecting 2023-08-21, the debugger retrieves me following data: Data selezionata per l'allenamento: 2023-08-20 22:00:00 +0000 Data troncata che verrà salvata: 2023-08-20 22:00:00 +0000 Data che verrà salvata: 2023-08-20 22:00:00 +0000 Allenamento salvato correttamente. The date you see and pick from a date picker is based on the current calendar and timezone on the device, while the debugger prints the date based on UTC timezone, as indicated by +0000. I believe that the current timezone on your device is different from UTC, and that would explain the difference you described. The difference between the values you see in the date picker and the debugger is not really an issue, because that is just two different views of the same value. To give you more context, a Date value is a double value that represents a number of seconds since 1970. Using a variety of calendars, timezones, and locales, an app can convert a Date value to different date strings, or convert a date string
Topic: Programming Languages SubTopic: Swift Tags:
Aug ’24
Reply to Date.FormatStyle.Symbol.Hour defaultDigits shows leading zero if amPM is set to .omitted
This is absolutely a bug in Foundation. The documentation and examples both say that the leading 0 shouldn't be included. Until the bug is fixes, the solutions available would be to either do string manipulation or to use a different format style. Each one has their own drawbacks when it comes to internationalization, so deciding which solution to use is a matter of weighing your needs against the drawbacks. 1. Trim Characters Simply check for the existence of a leading 0 character, and remove it if needed. // https://www.hackingwithswift.com/example-code/strings/how-to-remove-a-prefix-from-a-string extension String { func deletingPrefix(_ prefix: String) -> String { guard self.hasPrefix(prefix) else { return self } return String(self.dropFirst(prefix.count)) } } let testDate = try! Date(2024-01-01T10:36:01Z, strategy: .iso8601) let dateString = testDate.formatted(.dateTime.hour(.defaultDigits(amPM: .omitted)).minute()) // 03:36 dateString.deletingPrefix(0) // 3:36 This would only work for locales that use
Topic: App & System Services SubTopic: General Tags:
Aug ’24
Swiftdata with Date
Dear all, I'm going out of mind with the following issue. I have a view where I'm selecting a date through a datepicker. Then I'm inserting some other data and then I'm trying to save, see private func saveTraining(). But the date which is used to save the training is always one day before the selected date and more than this, I'm not able to save it without time. As I have then a calendar where the saved trainings need to be displayed, I'm not able to match it. Did anybody already face this issue? How can I solve it? I'm reporting here the code of the view where you can also find the checks I put to verify values/ dates: import SwiftData import AppKit struct AddTrainingView: View { @Environment(.modelContext) private var context @Binding var isAddingTraining: Bool @ObservedObject var season: Season @Binding var selectedDate: Date @State private var trainingStartTime = Date() @State private var trainingEndTime = Date() @State private var trainingConditionalGoal = @State private var trainingTacticalG
3
0
1.6k
Aug ’24
Looking for feedback on a Swift dev tool idea
I know this is a more abnormal question to ask on this forum but I really would like to gauge feedback from a community of other Swift developers on an idea. A colleague and I are seriously considering building a open-source web based SwiftUI component catalog that feature a collection of prebuilt modular components very similar to Shadcn for those of you who have worked in React but for SwiftUI where you can also contribute your own SwiftUI elements. Im curious if this would be something iOS/Swift devs would be possibly interested in and would love to hear thoughts on this idea. This is not a component library as Xcode technically has one thats built in, but rather fully built out SwiftUI elements such as UIs that use glass morphism for macOS, calendars for iOS apps, charts, etc.
1
0
576
Aug ’24
Mismatch between DayWeather date and HourWeather date
A year ago I filed feedback FB13055082 about this and I just realized that it was marked as works as currently designed. I need help understanding why this is the expected behavior. For the feedback example I used Nepal, which is +5:45 from GMT. When the UTC offset is not at an hour interval, the dates returned by DayWeather and HourWeather do not match. I’ll request weather with a start date of Aug 25 at 12:0:0 AM GMT+5:45 and end date of Sep 3 at 12:0:0 AM GMT+5:45. The first daily forecast returns a date of Aug 25, 2023 at 12:0:0 AM GMT+5:45, which is what I expect. It's midnight in Nepal and the start of the day. If in my code I call (correct calendar).startOfDay(for: ) I'll also get this same time back. However, the first hourly forecast returned is for Aug 25, 2023 at 12:45:0 AM GMT+5:45 which is NOT the start of the day in Nepal or the start I asked for. It is 45 minutes off. How is the hourly data not starting at the time I requested the expected behavior? Especially when the day data does st
1
0
576
Aug ’24
SwiftUI DatePicker color contrast
Hi! Is there a way to increase the color contrast of the calendar version of the SwiftUI DatePicker? Even with high contrast turned on in the general IOS settings, the contrast between the Sun, Mon, Tue etc and a plain white background is only 3.86:1, which is less than the WCAG AA recommendations of 4:5:1. The contrast with the text for non-selectable dates is even lower. I tried a couple of different options - setting tint, foregroundColor and so on, but they don't change the text color. Thanks in advance!
1
0
982
Jul ’24
ControlConfigurationIntent won't open the app despite setting openAppWhenRun = true
I am working on building Control widgets for our app and have noticed that openAppWhenRun doesn't seem to work for any ControlConfigurationIntent. When attaching the debugger to the widget extension in a sample project, I see the following error: Unknown NSError The operation couldn’t be completed. (LNActionExecutorErrorDomain error 2018.) This is reproducible as of Xcode 16.0 Beta 2 and Beta 3. I have noted that using an OpenIntent, with a parameter called target that conforms to AppEnum seems to open the app properly, but if I use that workaround, adding any additional parameters to the OpenIntent seems to break things again. Are others seeing this issue? I have feedback FB14357691. Here's some sample code below to reproduce: var body: some ControlWidgetConfiguration { AppIntentControlConfiguration(kind: Open Any Screen, intent: OpenAppScreenIntent.self) { template in ControlWidgetButton(action: template) { Label { Text(Open App) } icon: { Image(systemName: calendar) } }.tint(.red) } } } enum AppSc
6
0
2.0k
Jul ’24