Swiftpack.co - Swift Packages by readium

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.

Packages published by readium

readium/swift-toolkit 2.7.0
A toolkit for ebooks, audiobooks and comics written in Swift
⭐️ 198
🕓 2 weeks ago
🔖 Release Notes

Releases

The markdown parsing is broken/disabled for release notes. Sorry about that, I'm chasing the source of a crash that's been bringing this website down for the last couple of days.
2.7.0
2 weeks ago
[Take a look at the migration guide](Documentation/Migration%20Guide.md) ## Changelog ### Added #### Shared * You can now use `DefaultHTTPClientDelegate.httpClient(_:request:didReceive:completion:)` to handle authentication challenges (e.g. Basic) with `DefaultHTTPClient`. #### Navigator * The `AudioNavigator` API has been promoted to stable and ships with a new Preferences API. * The new `NavigatorDelegate.didFailToLoadResourceAt(_:didFailToLoadResourceAt:withError:)` delegate API notifies when an error occurs while loading a publication resource (contributed by [@ettore](https://github.com/readium/swift-toolkit/pull/400)). ### Fixed * [#390](https://github.com/readium/swift-toolkit/issues/390) Fixed logger not logging above the minimum severity level (contributed by [@ettore](https://github.com/readium/swift-toolkit/pull/391)). #### Navigator * From iOS 13 to 15, PDF text selection is disabled on protected publications disabling the **Copy** editing action. * The **Share** editing action is disabled for any protected publication. * Fixed starting the TTS from the current EPUB position. * [#396](https://github.com/readium/swift-toolkit/issues/396) Ensure we stop the activity indicator when an EPUB resource fails to load correctly (contributed by [@ettore](https://github.com/readium/swift-toolkit/pull/397)). #### Streamer * [#399](https://github.com/readium/swift-toolkit/discussions/399) Zipped Audio Books and standalone audio files are now recognized. ## Commits * Adjust the audio session strategy for the `AudioNavigator` by @mickael-menu in https://github.com/readium/swift-toolkit/pull/357 * Fix Copy and Share editing actions by @mickael-menu in https://github.com/readium/swift-toolkit/pull/364 * Fix 367: Fix initial location when in landscape landscape by @chrfalch in https://github.com/readium/swift-toolkit/pull/368 * Fix TTS issue by @mickael-menu in https://github.com/readium/swift-toolkit/pull/369 * Add a new form-based bug report issue template by @mickael-menu in https://github.com/readium/swift-toolkit/pull/374 * Update file headers by @mickael-menu in https://github.com/readium/swift-toolkit/pull/378 * Initial pass at `Locator.Locations.time` by @domkm in https://github.com/readium/swift-toolkit/pull/382 * Preferences API for `AudioNavigator` by @mickael-menu in https://github.com/readium/swift-toolkit/pull/389 * Compare loggable SeverityLevel by its numeric (not string) value by @ettore in https://github.com/readium/swift-toolkit/pull/391 * Switch to pnpm by @mickael-menu in https://github.com/readium/swift-toolkit/pull/392 * Turn off spinner if spread doesn't begin loading by @ettore in https://github.com/readium/swift-toolkit/pull/397 * Sniff audio clips by @mickael-menu in https://github.com/readium/swift-toolkit/pull/403 * Use ReadiumGCDWebServer* symbols by @ettore in https://github.com/readium/swift-toolkit/pull/404 * Bubble up errors while loading Resources by @ettore in https://github.com/readium/swift-toolkit/pull/400 * Fix ReadiumGCDWebServer integration for CocoaPods and Carthage by @mickael-menu in https://github.com/readium/swift-toolkit/pull/406 * Handle authentication challenges with `DefaultHTTPClient` by @mickael-menu in https://github.com/readium/swift-toolkit/pull/409 * 2.7.0 by @mickael-menu in https://github.com/readium/swift-toolkit/pull/410 ## New Contributors * @domkm made their first contribution in https://github.com/readium/swift-toolkit/pull/382 * @ettore made their first contribution in https://github.com/readium/swift-toolkit/pull/391 **Full Changelog**: https://github.com/readium/swift-toolkit/compare/2.6.1...2.7.0
2.6.1
25 weeks ago
[Take a look at the migration guide](Documentation/Migration%20Guide.md) ### Added #### Navigator * You can now customize the playback refresh rate of `_AudiobookNavigator` in its configuration. * The EPUB navigator automatically moves to the next resource when VoiceOver reaches the end of the current one. ### Changed #### Navigator * You should not subclass `PDFNavigatorViewController` anymore. If you need to override `setupPDFView`, you can do so by implementing the `PDFNavigatorDelegate` protocol. ### Fixed #### Shared * Zipped Audio Book archives are now detected even if they contain bitmap entries. #### Navigator * [#344](https://github.com/readium/swift-toolkit/issues/344) EPUB: Fixed lost position when rotating quickly the screen several times. * [#350](https://github.com/readium/swift-toolkit/discussions/350) Restore the ability to subclass the `PDFNavigatorViewController`. * Fixed activating the scroll mode when VoiceOver is enabled in the EPUB navigator.
2.6.0
30 weeks ago
[Take a look at the migration guide](Documentation/Migration%20Guide.md) * Support for Xcode 15. ### Added #### Navigator * The `PublicationSpeechSynthesizer` (TTS) now supports background playback by default. * You will need to enable the **Audio Background Mode** in your app's build info. * Support for non-linear EPUB resources with an opt-in in reading apps (contributed by @chrfalch in [#332](https://github.com/readium/swift-toolkit/pull/332) and [#331](https://github.com/readium/swift-toolkit/pull/331)). 1. Override loading non-linear resources with `VisualNavigatorDelegate.navigator(_:shouldNavigateToLink:)`. 2. Present a new `EPUBNavigatorViewController` by providing a custom `readingOrder` with only this resource to the constructor. ### Fixed #### Navigator * Improved performance when adding hundreds of HTML decorations at once. * Fixed broadcasting the `PublicationSpeechSynthesizer` with AirPlay when the screen is locked. ### Changed #### Navigator * `AudioSession` and `NowPlayingInfo` are now stable! * You need to provide the configuration of the Audio Session to the constructor of `PublicationSpeechSynthesizer`, instead of `AVTTSEngine`.
2.5.1
41 weeks ago
[Take a look at the migration guide](Documentation/Migration%20Guide.md) * The Readium toolkit now requires iOS 11.0+. ### Added #### Navigator * The `auto` spread setting is now available for fixed-layout EPUBs. It will display two pages in landscape and a single one in portrait. #### Streamer * The EPUB content iterator now returns `audio` and `video` elements and fill in the `progression` and `totalProgression` locator properties. ### Changed #### Navigator * `EPUBNavigatorViewController.firstVisibleElementLocator()` now returns the first *block* element that is visible on the screen, even if it starts on previous pages. * This is used to make sure the user will not miss any context when restoring a TTS session in the middle of a resource. ### Fixed #### Navigator * Fixed the PDF `auto` spread setting and scaling pages when rotating the screen. * Fixed navigating to the first chapter of an audiobook with a single resource (contributed by [@grighakobian](https://github.com/readium/swift-toolkit/pull/292)). * Prevent auto-playing videos in EPUB publications. * Fixed various memory leaks and data races. * The `WKWebView` is now inspectable again with Safari starting from iOS 16.4. * Fixed crash in the `PublicationSpeechSynthesizer` when closing the navigator without stopping it first. * Fixed pausing the `PublicationSpeechSynthesizer` right before starting the utterance. * Fixed the audio session kept opened while the app is in the background and paused. * Fixed the **Attribute dir redefined** error when the EPUB resource already has a `dir` attribute. * [#309](https://github.com/readium/swift-toolkit/issues/309) Fixed restoring the EPUB location when the application was killed in the background (contributed by [@triin-ko](https://github.com/readium/swift-toolkit/pull/311)). #### Streamer * Fix issue with the TTS starting from the beginning of the chapter instead of the current position.
2.5.0
1 year ago
[Take a look at the migration guide](Documentation/Migration%20Guide.md) ### Added #### Streamer * Positions computation, TTS and search is now enabled for Readium Web Publications conforming to the [EPUB profile](https://readium.org/webpub-manifest/profiles/epub.html). #### Navigator * New `VisualNavigatorDelegate` APIs to handle keyboard events (contributed by [@lukeslu](https://github.com/readium/swift-toolkit/pull/267)). * This can be used to turn pages with the arrow keys, for example. * [Support for custom fonts with the EPUB navigator](Documentation/Guides/EPUB%20Fonts.md). * A brand new user preferences API for configuring the EPUB and PDF Navigators. This new API is easier and safer to use. To learn how to integrate it in your app, [please refer to the user guide](Documentation/Guides/Navigator%20Preferences.md) and [migration guide](Documentation/Migration%20Guide.md). * New EPUB user preferences: * `fontWeight` - Base text font weight. * `textNormalization` - Normalize font style, weight and variants, which improves accessibility. * `imageFilter` - Filter applied to images in dark theme (darken, invert colors) * `language` - Language of the publication content. * `readingProgression` - Direction of the reading progression across resources, e.g. RTL. * `typeScale` - Scale applied to all element font sizes. * `paragraphIndent` - Text indentation for paragraphs. * `paragraphSpacing` - Vertical margins for paragraphs. * `hyphens` - Enable hyphenation. * `ligatures` - Enable ligatures in Arabic. * New PDF user preferences: * `backgroundColor` - Background color behind the document pages. * `offsetFirstPage` - Indicate if the first page should be displayed in its own spread. * `pageSpacing` - Spacing between pages in points. * `readingProgression` - Direction of the reading progression across resources, e.g. RTL. * `scrollAxis` - Scrolling direction when `scroll` is enabled. * `scroll` - Indicate if pages should be handled using scrolling instead of pagination. * `spread` - Enable dual-page mode. * `visibleScrollbar` - Indicate whether the scrollbar should be visible while scrolling. * The new `DirectionalNavigationAdapter` component helps you to turn pages with the arrows and space keyboard keys or taps on the edge of the screen. ### Deprecated #### Streamer * `PublicationServer` is deprecated. See the [the migration guide](Documentation/Migration%20Guide.md#2.5.0) to migrate the HTTP server. #### Navigator * The EPUB `UserSettings` component is deprecated and replaced by the new Preferences API. [Take a look at the user guide](Documentation/Guides/Navigator%20Preferences.md) and [migration guide](Documentation/Migration%20Guide.md). ### Changed #### Navigator * The `define` editing action replaces `lookup` on iOS 16+. When enabled, it will show both the "Look Up" and "Search Web" menu items. * Prevent navigation in the EPUB while it is being loaded. ### Fixed #### Navigator * Fixed a race condition issue with the `AVTTSEngine`, when pausing utterances. * Fixed crash with `PublicationSpeechSynthesizer`, when the currently played word cannot be resolved. * Fixed EPUB tap event sent twice when using a mouse (e.g. on Apple Silicon or with a mouse on an iPad).
2.4.0
1 year ago
[Take a look at the migration guide](Documentation/Migration%20Guide.md) ### Added #### Shared * Support for the accessibility metadata in RWPM per [Schema.org Accessibility Properties for Discoverability Vocabulary](https://www.w3.org/2021/a11y-discov-vocab/latest/). * [Extract the raw content (text, images, etc.) of a publication](Documentation/Guides/Content.md). #### Navigator * [A brand new text-to-speech implementation](Documentation/Guides/TTS.md). #### Streamer * Parse EPUB accessibility metadata ([see documentation](https://readium.org/architecture/streamer/parser/a11y-metadata-parsing)). ### Deprecated #### Shared * `Locator(link: Link)` is deprecated as it may create an incorrect `Locator` if the link `type` is missing. * Use `publication.locate(Link)` instead. ### Fixed * [#244](https://github.com/readium/swift-toolkit/issues/244) Fixed build with Xcode 14 and Carthage/CocoaPods. #### Navigator * Fixed memory leaks in the EPUB and PDF navigators. * [#61](https://github.com/readium/swift-toolkit/issues/61) Fixed serving EPUB resources when the HREF contains an anchor or query parameters. * Performance issue with EPUB fixed-layout when spreads are enabled. * Disable scrolling in EPUB fixed-layout resources, in case the viewport is incorrectly set. * Fix vertically bouncing EPUB resources in iOS 16. #### Streamer * Fixed memory leak in the `PublicationServer`. #### LCP * The LCP authentication dialog is now fully localized and supports Dark Mode (contributed by [@openm1nd](https://github.com/readium/swift-toolkit/pull/50)).
2.3.0
2 years ago
[Take a look at the migration guide](Documentation/Migration%20Guide.md) ### Added #### Shared * Get the sanitized `Locator` text ready for user display with `locator.text.sanitized()`. * A new `Publication.conforms(to:)` API to identify the profile of a publication. * Support for the [`conformsTo` RWPM metadata](https://github.com/readium/webpub-manifest/issues/65), to identify the profile of a `Publication`. * Support for right-to-left PDF documents by extracting the reading progression from the `ViewerPreferences/Direction` metadata. * HTTP client: * A new `HTTPClient.download()` API to download HTTP resources to a temporary location. * `HTTPRequest` and `DefaultHTTPClient` take an optional `userAgent` property to customize the user agent. #### Navigator * The new `NavigatorDelegate.navigator(_:didJumpTo:)` API is called every time the navigator jumps to an explicit location, which might break the linear reading progression. * For example, it is called when clicking on internal links or programmatically calling `Navigator.go(to:)`, but not when turning pages. * You can use this callback to implement a navigation history by differentiating between continuous and discontinuous moves. ### Deprecated #### Shared * `Publication.format` is now deprecated in favor of the new `Publication.conforms(to:)` API which is more accurate. * For example, replace `publication.format == .epub` with `publication.conforms(to: .epub)` before opening a publication with the `EPUBNavigatorViewController`. ### Changed #### LCP * The `LCPService` now uses a provided `HTTPClient` instance for all HTTP requests. ### Fixed #### Navigator * [#14](https://github.com/readium/swift-toolkit/issues/14) Backward compatibility (iOS 10+) of JavaScript files is now handled with Babel. * Throttle the reload of EPUB spreads to avoid losing the position when the reader gets back to the foreground. #### LCP * Fixed the notification of acquisition progress.
2.2.0
2 years ago
[Take a look at the migration guide](Documentation/Migration%20Guide.md) ### Added #### Shared * Support for Paragraph Margins user setting. #### Navigator * A new `translate` EPUB and PDF editing action is available for iOS 15. ### Fixed #### Shared * Improved performances of the search service used with EPUB. #### Navigator * Fixed turning pages of an EPUB reflowable resource with an odd number of columns. A virtual blank trailing column is appended to the resource when displayed as two columns.
iOS
readium/r2-lcp-swift 2.2.0
Swift LCP module
⭐️ 5
🕓 2 years ago
🔖 Release Notes

Releases

The markdown parsing is broken/disabled for release notes. Sorry about that, I'm chasing the source of a crash that's been bringing this website down for the last couple of days.
2.2.0
2 years ago
[Take a look at the migration guide](https://readium.org/mobile/swift/migration-guide) Nothing new for `r2-lcp-swift` in Readium Swift 2.2.0.
2.1.1
2 years ago
[Take a look at the migration guide](https://readium.org/mobile/swift/migration-guide) ### Fixed * Fix crash using the default `LCPDialogViewController` with CocoaPods.
2.1.0
2 years ago
[Take a look at the migration guide](https://readium.org/mobile/swift/migration-guide) ### Added * Support for Swift Package Manager (contributed by [@stevenzeck](https://github.com/readium/r2-lcp-swift/pull/121)).
2.0.0
2 years ago
[Take a look at the migration guide](https://readium.org/mobile/swift/migration-guide) ### Deprecated * All APIs deprecated in previous versions are now unavailable.
2.0.0-beta.2
3 years ago
[Take a look at the migration guide](https://readium.org/mobile/swift/migration-guide) ### Changed * We removed the dependency to the private `R2LCPClient.framework`, which means: * Now `r2-lcp-swift` works as a Carthage dependency, no need to use a submodule anymore. * You do not need to modify `r2-lcp-swift`'s `Cartfile` anymore to add the private `liblcp` dependency. * However, you must provide a facade to `LCPService` (see [README](README.md) for an example implementation). * The Renew Loan API got revamped to better support renewal through a web page. * You will need to implement `LCPRenewDelegate` to coordinate the UX interaction. * Readium ships with a default implementation `LCPDefaultRenewDelegate` to handle web page renewal with `SFSafariViewController`. ### Fixed * Fixed really slow opening of large PDF documents.
2.0.0-beta.1
3 years ago
[Take a look at the migration guide](https://readium.org/mobile/swift/migration-guide) ### Changed * Upgraded shared dependencies.
2.0.0-alpha.2
3 years ago
[Take a look at the migration guide](https://readium.org/mobile/swift/migration-guide) ### Added * LCP implementation of the [Content Protection API](https://readium.org/architecture/proposals/006-content-protection) to work with the new [Streamer API](https://readium.org/architecture/proposals/005-streamer-api). * It is highly recommended that you upgrade to the new `Streamer` API to open publications, which will simplify DRM unlocking. * Two default implementations of `LCPAuthenticating`: * `LCPDialogAuthentication` to prompt the user for its passphrase with the official LCP dialog. * `LCPPassphraseAuthentication` to provide directly a passphrase, pulled for example from a database or a web service. * `LCPService.acquirePublication()` is a new API to acquire a publication from a standalone license. Compared to the former `importPublication()`: * It doesn't require the passphrase, to allow bulk imports. * It can be cancelled by calling `cancel()` on the returned `LCPAcquisition` object. * `LCPService.isLCPProtected()` provides a way to check if a file is protected with LCP. ### Changed * `LCPAuthenticating` is now provided with more information and you will need to update your implementation. ### Fixed * [Decrypting resources in some edge cases](https://github.com/readium/r2-lcp-swift/pull/94).
2.0.0-alpha.1
3 years ago
### Added * Support for [PDF](https://readium.org/lcp-specs/notes/lcp-for-pdf.html) and [Readium Audiobooks](https://readium.org/lcp-specs/notes/lcp-for-audiobooks.html) protected with LCP. ### Changed * `LCPAuthenticating` can now return hashed passphrases in addition to clear ones. [This can be used by reading apps](https://github.com/readium/r2-lcp-swift/pull/75) fetching hashed passphrases from a web service or [Authentication for OPDS](https://readium.org/lcp-specs/notes/lcp-key-retrieval.html), for example. * Provided `LCPAuthenticating` instances are now retained by the LCP service. Therefore, you can provide one without keeping a reference around in your own code.
4 years ago
4 years ago
iOS

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics