
Paperkit
Add system-standard markup—drawings, shapes, and annotations—in a Swift iOS app with PaperMarkupViewController and PaperKit models.
Overview
PaperKit is an agent skill for the Build phase that guides integration of Apple PaperKit markup—PaperMarkupViewController, data models, and SwiftUI embedding—for annotation features on iOS 26 and related platforms.
Install
npx skills add https://github.com/dpearson2699/swift-ios-skills --skill paperkitWhat is this skill?
- PaperMarkupViewController as the unified markup editor shell used across Apple apps
- PaperMarkup data model with insertion controllers and FeatureSet configuration
- PencilKit and structured shapes, text boxes, images, and lines on one canvas
- SwiftUI integration patterns plus a dedicated review checklist before ship
- Beta-sensitive: iOS/iPadOS/macOS/visionOS 26+ and Swift 6.3 SDK requirements
- Requires Swift 6.3 and iOS 26+ SDK
- Includes a dedicated review checklist section in SKILL.md
Adoption & trust: 1.2k installs on skills.sh; 713 GitHub stars; 3/3 security scanners passed (skills.sh audits).
What problem does it solve?
You need Notes-quality markup in your app but PaperKit is new, beta-prone, and easy to misconfigure across controllers, models, and PencilKit.
Who is it for?
Solo builders on iOS 26+ adding annotation, document markup, or editor-embedded toolbars with PaperKit and SwiftUI.
Skip if: Apps that must support pre–iOS 26, web-only markup, or teams unwilling to verify APIs against live Apple documentation during beta cycles.
When should I use this skill?
Integrating PaperMarkupViewController, shape recognition, PaperMarkup models, markup toolbars in document editors, or system-standard annotation on iOS 26+.
What do I get? / Deliverables
You implement a consistent markup experience with documented setup, FeatureSet choices, and a pre-ship review checklist aligned to current Apple APIs.
- Integration plan for PaperMarkupViewController
- FeatureSet and insertion-controller configuration notes
- Review-checklist pass before release
Recommended Skills
Journey fit
Build is where you integrate Apple’s markup UI and data models into an app feature, not where you validate or operate production monitoring. Frontend covers in-app markup surfaces, toolbars, and SwiftUI/UIKit embedding for user-facing annotation experiences.
How it compares
Apple’s unified markup framework integration skill—not a cross-platform canvas library or a pure PencilKit-only drawing tutorial.
Common Questions / FAQ
Who is paperkit for?
Indie and solo iOS developers integrating first-party markup in Swift apps on the iOS 26 family SDKs.
When should I use paperkit?
Use it during Build (frontend) when integrating PaperMarkupViewController, shape recognition, PaperMarkup persistence, or SwiftUI-hosted markup tools in a document or reader app.
Is paperkit safe to install?
It is documentation-style guidance with no special entitlements described; review the Security Audits panel on this Prism page and re-verify Apple APIs before production releases.
SKILL.md
READMESKILL.md - Paperkit
# PaperKit > **Beta-sensitive.** PaperKit is new in iOS/iPadOS 26, macOS 26, and visionOS 26. API surface may change. Verify details against current Apple documentation before shipping. PaperKit provides a unified markup experience — the same framework powering markup in Notes, Screenshots, QuickLook, and Journal. It combines PencilKit drawing with structured markup elements (shapes, text boxes, images, lines) in a single canvas managed by `PaperMarkupViewController`. Requires Swift 6.3 and the iOS 26+ SDK. ## Contents - [Setup](#setup) - [PaperMarkupViewController](#papermarkupviewcontroller) - [PaperMarkup Data Model](#papermarkup-data-model) - [Insertion Controllers](#insertion-controllers) - [FeatureSet Configuration](#featureset-configuration) - [Integration with PencilKit](#integration-with-pencilkit) - [SwiftUI Integration](#swiftui-integration) - [Common Mistakes](#common-mistakes) - [Review Checklist](#review-checklist) - [References](#references) ## Setup PaperKit requires no entitlements or special Info.plist entries. ```swift import PaperKit ``` **Platform availability:** iOS 26.0+, iPadOS 26.0+, Mac Catalyst 26.0+, macOS 26.0+, visionOS 26.0+. Three core components: | Component | Role | |---|---| | `PaperMarkupViewController` | Interactive canvas for creating and displaying markup and drawing | | `PaperMarkup` | Data model for serializing all markup elements and PencilKit drawing | | `MarkupEditViewController` / `MarkupToolbarViewController` | Insertion UI for adding markup elements | ## PaperMarkupViewController The primary view controller for interactive markup. Provides a scrollable canvas for freeform PencilKit drawing and structured markup elements. Conforms to `Observable` and `PKToolPickerObserver`. ### Basic UIKit Setup ```swift import PaperKit import PencilKit import UIKit class MarkupViewController: UIViewController, PaperMarkupViewController.Delegate { var paperVC: PaperMarkupViewController! var toolPicker: PKToolPicker! override func viewDidLoad() { super.viewDidLoad() let markup = PaperMarkup(bounds: view.bounds) paperVC = PaperMarkupViewController( markup: markup, supportedFeatureSet: .latest ) paperVC.delegate = self addChild(paperVC) paperVC.view.frame = view.bounds paperVC.view.autoresizingMask = [.flexibleWidth, .flexibleHeight] view.addSubview(paperVC.view) paperVC.didMove(toParent: self) toolPicker = PKToolPicker() toolPicker.addObserver(paperVC) paperVC.pencilKitResponderState.activeToolPicker = toolPicker paperVC.pencilKitResponderState.toolPickerVisibility = .visible } func paperMarkupViewControllerDidChangeMarkup( _ controller: PaperMarkupViewController ) { guard let markup = controller.markup else { return } Task { try await save(markup) } } } ``` ### Key Properties | Property | Type | Description | |---|---|---| | `markup` | `PaperMarkup?` | The current data model | | `selectedMarkup` | `PaperMarkup` | Currently selected content | | `isEditable` | `Bool` | Whether the canvas accepts input | | `isRulerActive` | `Bool` | Whether the ruler overlay is shown | | `drawingTool` | `any PKTool` | Active PencilKit drawing tool | | `contentView` | `UIView?` / `NSView?` | Background view rendered beneath markup | | `zoomRange` | `ClosedRange<CGFloat>` | Min/max zoom scale | | `supportedFeatureSet` | `FeatureSet` | Enabled PaperKit features | ### Touch Modes `PaperMarkupViewController.TouchMode` has two cases: `.drawing`