@capgo/capacitor-printer 7.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,17 @@
1
+ require 'json'
2
+
3
+ package = JSON.parse(File.read(File.join(__dir__, 'package.json')))
4
+
5
+ Pod::Spec.new do |s|
6
+ s.name = 'CapgoPrinter'
7
+ s.version = package['version']
8
+ s.summary = package['description']
9
+ s.license = package['license']
10
+ s.homepage = package['repository']['url']
11
+ s.author = package['author']
12
+ s.source = { :git => package['repository']['url'], :tag => s.version.to_s }
13
+ s.source_files = 'ios/Sources/**/*.{swift,h,m,c,cc,mm,cpp}'
14
+ s.ios.deployment_target = '13.0'
15
+ s.dependency 'Capacitor'
16
+ s.swift_version = '5.1'
17
+ end
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2025 Martin Donadieu
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/Package.swift ADDED
@@ -0,0 +1,28 @@
1
+ // swift-tools-version: 5.9
2
+ import PackageDescription
3
+
4
+ let package = Package(
5
+ name: "CapgoPrinter",
6
+ platforms: [.iOS(.v13)],
7
+ products: [
8
+ .library(
9
+ name: "CapgoPrinter",
10
+ targets: ["PrinterPlugin"])
11
+ ],
12
+ dependencies: [
13
+ .package(url: "https://github.com/ionic-team/capacitor-swift-pm.git", branch: "7.0.0")
14
+ ],
15
+ targets: [
16
+ .target(
17
+ name: "PrinterPlugin",
18
+ dependencies: [
19
+ .product(name: "Capacitor", package: "capacitor-swift-pm"),
20
+ .product(name: "Cordova", package: "capacitor-swift-pm")
21
+ ],
22
+ path: "ios/Sources/PrinterPlugin"),
23
+ .testTarget(
24
+ name: "PrinterPluginTests",
25
+ dependencies: ["PrinterPlugin"],
26
+ path: "ios/Tests/PrinterPluginTests")
27
+ ]
28
+ )
package/README.md ADDED
@@ -0,0 +1,353 @@
1
+ # @capgo/capacitor-printer
2
+ <a href="https://capgo.app/"><img src='https://raw.githubusercontent.com/Cap-go/capgo/main/assets/capgo_banner.png' alt='Capgo - Instant updates for capacitor'/></a>
3
+
4
+ <div align="center">
5
+ <h2><a href="https://capgo.app/?ref=plugin"> ➡️ Get Instant updates for your App with Capgo</a></h2>
6
+ <h2><a href="https://capgo.app/consulting/?ref=plugin"> Missing a feature? We'll build the plugin for you 💪</a></h2>
7
+ </div>
8
+
9
+ Capacitor plugin for printing documents, HTML, PDFs, images and web views on iOS and Android.
10
+
11
+ ## Why Capacitor Printer?
12
+
13
+ A **free and open-source** printing solution with comprehensive features:
14
+
15
+ - **Multiple formats** - Print HTML, PDFs, images, and base64 data
16
+ - **Native APIs** - Uses UIPrintInteractionController (iOS) and PrintManager (Android)
17
+ - **Web support** - Works across all platforms including web browsers
18
+ - **Print customization** - Support for CSS print styles and custom page names
19
+ - **Cross-platform** - Consistent API across iOS, Android, and Web
20
+
21
+ Perfect for invoice generation, report printing, document sharing, and any app requiring native printing capabilities.
22
+
23
+ ## Documentation
24
+
25
+ The most complete doc is available here: https://capgo.app/docs/plugins/printer/
26
+
27
+ ## Install
28
+
29
+ ```bash
30
+ npm install @capgo/capacitor-printer
31
+ npx cap sync
32
+ ```
33
+
34
+ ## Usage
35
+
36
+ ```typescript
37
+ import { Printer } from '@capgo/capacitor-printer';
38
+
39
+ // Print HTML content
40
+ await Printer.printHtml({
41
+ name: 'My Document',
42
+ html: '<html><body><h1>Hello World</h1><p>This is a test document.</p></body></html>',
43
+ });
44
+
45
+ // Print PDF file
46
+ await Printer.printPdf({
47
+ name: 'Invoice',
48
+ path: 'file:///path/to/document.pdf',
49
+ });
50
+
51
+ // Print image from base64
52
+ await Printer.printBase64({
53
+ name: 'Photo',
54
+ data: 'JVBERi0xLjQKJeLjz9MKMyAwIG9iago8PC9UeXBlL...',
55
+ mimeType: 'image/jpeg',
56
+ });
57
+
58
+ // Print current web view
59
+ await Printer.printWebView({
60
+ name: 'Web Page',
61
+ });
62
+ ```
63
+
64
+ ## API
65
+
66
+ <docgen-index>
67
+
68
+ * [`printBase64(...)`](#printbase64)
69
+ * [`printFile(...)`](#printfile)
70
+ * [`printHtml(...)`](#printhtml)
71
+ * [`printPdf(...)`](#printpdf)
72
+ * [`printWebView(...)`](#printwebview)
73
+ * [`getPluginVersion()`](#getpluginversion)
74
+ * [Interfaces](#interfaces)
75
+
76
+ </docgen-index>
77
+
78
+ <docgen-api>
79
+ <!--Update the source file JSDoc comments and rerun docgen to update the docs below-->
80
+
81
+ ### printBase64(...)
82
+
83
+ ```typescript
84
+ printBase64(options: PrintBase64Options) => Promise<void>
85
+ ```
86
+
87
+ Presents the printing UI to print files encoded as base64 strings.
88
+
89
+ **Platform Behavior:**
90
+ - **iOS**: Uses UIPrintInteractionController with base64 decoded data
91
+ - **Android**: Uses PrintManager with base64 decoded data
92
+ - **Web**: Creates a blob from base64 data and opens print dialog
93
+
94
+ **Performance Warning:**
95
+ Large files can lead to app crashes due to memory constraints when decoding base64.
96
+ For files larger than 5MB, it's recommended to use printFile() instead.
97
+
98
+ | Param | Type | Description |
99
+ | ------------- | ----------------------------------------------------------------- | ------------------------------------------------ |
100
+ | **`options`** | <code><a href="#printbase64options">PrintBase64Options</a></code> | - The base64 data and configuration for printing |
101
+
102
+ **Since:** 7.0.0
103
+
104
+ --------------------
105
+
106
+
107
+ ### printFile(...)
108
+
109
+ ```typescript
110
+ printFile(options: PrintFileOptions) => Promise<void>
111
+ ```
112
+
113
+ Presents the printing UI to print device files.
114
+
115
+ **Platform Behavior:**
116
+ - **iOS**: Uses UIPrintInteractionController with file URL. Supports file:// paths or paths relative to app's documents directory.
117
+ - **Android**: Uses PrintManager with file path. Supports both content:// URIs and file:// paths.
118
+ - **Web**: Reads file and opens print dialog
119
+
120
+ **Supported File Types:**
121
+ - PDF documents (application/pdf)
122
+ - Images: JPEG, PNG, GIF, HEIC, HEIF
123
+
124
+ | Param | Type | Description |
125
+ | ------------- | ------------------------------------------------------------- | ---------------------------------------------- |
126
+ | **`options`** | <code><a href="#printfileoptions">PrintFileOptions</a></code> | - The file path and configuration for printing |
127
+
128
+ **Since:** 7.0.0
129
+
130
+ --------------------
131
+
132
+
133
+ ### printHtml(...)
134
+
135
+ ```typescript
136
+ printHtml(options: PrintHtmlOptions) => Promise<void>
137
+ ```
138
+
139
+ Presents the printing UI to print HTML documents.
140
+
141
+ **Platform Behavior:**
142
+ - **iOS**: Renders HTML in WKWebView, then prints using UIPrintInteractionController
143
+ - **Android**: Renders HTML in WebView, then prints using PrintManager
144
+ - **Web**: Creates iframe with HTML content and triggers print dialog
145
+
146
+ **HTML Requirements:**
147
+ - Should be a complete HTML document with proper structure
148
+ - Can include inline CSS styles or style tags
149
+ - External resources (images, stylesheets) should use absolute URLs
150
+ - Print-specific CSS can be added using @media print rules
151
+
152
+ **CSS Print Styling:**
153
+ Use CSS media queries to customize print output:
154
+ - Control page breaks: page-break-before, page-break-after, page-break-inside
155
+ - Hide elements: display: none for no-print classes
156
+ - Adjust font sizes and colors for print
157
+
158
+ | Param | Type | Description |
159
+ | ------------- | ------------------------------------------------------------- | ------------------------------------------------- |
160
+ | **`options`** | <code><a href="#printhtmloptions">PrintHtmlOptions</a></code> | - The HTML content and configuration for printing |
161
+
162
+ **Since:** 7.0.0
163
+
164
+ --------------------
165
+
166
+
167
+ ### printPdf(...)
168
+
169
+ ```typescript
170
+ printPdf(options: PrintPdfOptions) => Promise<void>
171
+ ```
172
+
173
+ Presents the printing UI to print PDF documents.
174
+
175
+ **Platform Behavior:**
176
+ - **iOS**: Uses UIPrintInteractionController with PDF file URL
177
+ - **Android**: Uses PrintManager with PdfDocument
178
+ - **Web**: Creates object URL and opens print dialog
179
+
180
+ **File Path Requirements:**
181
+ - **iOS**: Must be file:// path or relative to app's documents directory
182
+ - **Android**: Supports content:// URIs (from downloads, media store) or file:// paths
183
+ - **Web**: Must be accessible file path
184
+
185
+ | Param | Type | Description |
186
+ | ------------- | ----------------------------------------------------------- | -------------------------------------------------- |
187
+ | **`options`** | <code><a href="#printpdfoptions">PrintPdfOptions</a></code> | - The PDF file path and configuration for printing |
188
+
189
+ **Since:** 7.0.0
190
+
191
+ --------------------
192
+
193
+
194
+ ### printWebView(...)
195
+
196
+ ```typescript
197
+ printWebView(options?: PrintOptions | undefined) => Promise<void>
198
+ ```
199
+
200
+ Presents the printing UI to print web view content.
201
+
202
+ Prints the current content displayed in your app's web view.
203
+
204
+ **Platform Behavior:**
205
+ - **iOS**: Uses UIPrintInteractionController with WKWebView's view printable
206
+ - **Android**: Uses WebView.createPrintDocumentAdapter() with PrintManager
207
+ - **Web**: Triggers window.print() for current page
208
+
209
+ **Print Styling:**
210
+ Supports CSS print media queries for customization. The web view's current
211
+ styles will be applied, including any @media print rules.
212
+
213
+ **Use Cases:**
214
+ - Print the current app screen/page
215
+ - Print web-based reports or dashboards
216
+ - Print user-generated content displayed in web view
217
+
218
+ | Param | Type | Description |
219
+ | ------------- | ----------------------------------------------------- | ------------------------------------------------- |
220
+ | **`options`** | <code><a href="#printoptions">PrintOptions</a></code> | - Optional configuration for printing (name only) |
221
+
222
+ **Since:** 7.0.0
223
+
224
+ --------------------
225
+
226
+
227
+ ### getPluginVersion()
228
+
229
+ ```typescript
230
+ getPluginVersion() => Promise<{ version: string; }>
231
+ ```
232
+
233
+ Get the native Capacitor plugin version.
234
+
235
+ Returns the hardcoded plugin version from native code (iOS/Android) or
236
+ package version (Web). This is useful for debugging and ensuring plugin
237
+ compatibility.
238
+
239
+ **Returns:** <code>Promise&lt;{ version: string; }&gt;</code>
240
+
241
+ **Since:** 7.0.0
242
+
243
+ --------------------
244
+
245
+
246
+ ### Interfaces
247
+
248
+
249
+ #### PrintBase64Options
250
+
251
+ Options for printing base64 encoded data.
252
+
253
+ | Prop | Type | Description | Since |
254
+ | -------------- | ------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----- |
255
+ | **`data`** | <code>string</code> | Valid base64 encoded string representing the file content. The base64 string should NOT include the data URL prefix (e.g., "data:application/pdf;base64,"). Only provide the raw base64 encoded content. **Performance Considerations:** - Base64 encoding increases data size by approximately 33% - Large files (&gt;5MB) may cause memory issues when decoding - Consider using printFile() for large documents **Platform Notes:** - **iOS**: Decoded to NSData and passed to UIPrintInteractionController - **Android**: Decoded to byte array and written to temporary file - **Web**: Converted to Blob for printing | 7.0.0 |
256
+ | **`mimeType`** | <code>string</code> | MIME type of the base64 encoded data. **Supported types:** - `application/pdf` - PDF documents - `image/jpeg` - JPEG images - `image/png` - PNG images - `image/gif` - GIF images (iOS/Android only) - `image/heic` - HEIC images (iOS only) - `image/heif` - HEIF images (iOS only) **Platform Support:** - All platforms support PDF, JPEG, and PNG - GIF support varies by platform - HEIC/HEIF are iOS-specific formats | 7.0.0 |
257
+
258
+
259
+ #### PrintFileOptions
260
+
261
+ Options for printing files from device storage.
262
+
263
+ | Prop | Type | Description | Default | Since |
264
+ | -------------- | ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ---------------------------------------------------------- | ----- |
265
+ | **`path`** | <code>string</code> | Path to the file to print. **iOS Path Formats:** - `file://` URL: Full file URL path - Relative path: Path relative to app's documents directory - Must be within app's accessible directories (documents, temporary, cache) **Android Path Formats:** - `content://` URI: Content provider URI (recommended for external files) - `file://` path: Direct file system path - Must have read permission for the file **Common Use Cases:** - App documents: Files saved in app's document directory - Downloads: Files from system downloads folder (use content:// on Android) - Temporary files: Files in app's temporary/cache directory - Shared storage: Files from external storage (Android, requires permissions) | | 7.0.0 |
266
+ | **`mimeType`** | <code>string</code> | MIME type of the file. **Platform Behavior:** - **Android**: REQUIRED for content:// URIs. Helps the system determine how to handle the file. Optional for file:// paths (auto-detected from extension). - **iOS**: Ignored. File type is auto-detected from file extension. - **Web**: Optional. Auto-detected if not provided. **Common MIME Types:** - `application/pdf` - PDF documents - `image/jpeg` - JPEG images - `image/png` - PNG images - `image/gif` - GIF images | <code>Undefined (auto-detected from file extension)</code> | 7.0.0 |
267
+
268
+
269
+ #### PrintHtmlOptions
270
+
271
+ Options for printing HTML content.
272
+
273
+ | Prop | Type | Description | Since |
274
+ | ---------- | ------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----- |
275
+ | **`html`** | <code>string</code> | HTML content to print. **Content Requirements:** - Should be a complete HTML document with `&lt;html&gt;`, `&lt;head&gt;`, and `&lt;body&gt;` tags - Can include inline CSS styles or `&lt;style&gt;` tags - External resources (images, fonts) should use absolute URLs - JavaScript is not executed during print rendering **Print Optimization Tips:** - Use `@media print` CSS rules for print-specific styling - Control page breaks with `page-break-before`, `page-break-after`, `page-break-inside` - Hide UI elements using `.no-print { display: none; }` class - Adjust font sizes for readability (12pt is standard for print) - Use print-friendly colors (avoid dark backgrounds) **Platform Rendering:** - **iOS**: Rendered in WKWebView before printing - **Android**: Rendered in WebView before printing - **Web**: Rendered in hidden iframe before printing **Character Encoding:** - UTF-8 is recommended and default - Include charset in HTML: `&lt;meta charset="UTF-8"&gt;` | 7.0.0 |
276
+
277
+
278
+ #### PrintPdfOptions
279
+
280
+ Options for printing PDF documents.
281
+
282
+ | Prop | Type | Description | Since |
283
+ | ---------- | ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ----- |
284
+ | **`path`** | <code>string</code> | Path to the PDF document. **iOS Path Formats:** - `file://` URL: Full file URL path to PDF document - Relative path: Path relative to app's documents directory - Must be within app's accessible directories (documents, temporary, cache) - PDF must be valid and not password-protected **Android Path Formats:** - `content://` URI: Content provider URI (recommended for external PDFs) - `file://` path: Direct file system path to PDF - Must have read permission for the file - Supports both single-page and multi-page PDFs **Web Path Formats:** - Relative or absolute path accessible from web context - Must be a valid PDF file **Validation:** - File must exist at the specified path - File must be a valid PDF (checked by magic number/header) - File must be readable by the app **Common Sources:** - App documents: PDFs saved in app's document directory - Downloads: PDFs from system downloads (use content:// on Android) - Generated PDFs: Temporary PDFs created by the app - Network downloads: PDFs downloaded and saved locally | 7.0.0 |
285
+
286
+
287
+ #### PrintOptions
288
+
289
+ Base options for all print operations.
290
+
291
+ | Prop | Type | Description | Default | Since |
292
+ | ---------- | ------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------- | ----- |
293
+ | **`name`** | <code>string</code> | Name of the print job. **Usage:** - Displayed in the system print queue - Shown in print history/logs - May appear in printer status displays - Used as default filename for "Save as PDF" option **Platform Behavior:** - **iOS**: Shown in print preview header and activity view - **Android**: Displayed in print job notification and print queue - **Web**: Used as document title in print dialog **Best Practices:** - Use descriptive names (e.g., "Invoice #12345", "Q4 Report") - Keep under 50 characters for better display - Avoid special characters that may cause issues in filenames - Include relevant identifiers (order numbers, dates, etc.) **Examples:** - "Invoice #12345" - "Sales Report - 2024 Q4" - "Customer Receipt - John Doe" - "Product Photo - SKU-ABC123" | <code>'Document'</code> | 7.0.0 |
294
+
295
+ </docgen-api>
296
+
297
+ ## Android Configuration
298
+
299
+ ### ProGuard
300
+
301
+ If you are using ProGuard, add the following rules to your `proguard-rules.pro` file:
302
+
303
+ ```pro
304
+ -keep class com.capgo.printer.** { *; }
305
+ ```
306
+
307
+ ### Variables
308
+
309
+ You can configure the following project variables in your `variables.gradle` file:
310
+
311
+ ```gradle
312
+ ext {
313
+ androidxDocumentFileVersion = '1.0.1'
314
+ androidxPrintVersion = '1.0.0'
315
+ }
316
+ ```
317
+
318
+ ## Platform Support
319
+
320
+ | Platform | Supported |
321
+ | -------- | --------- |
322
+ | iOS | ✅ |
323
+ | Android | ✅ |
324
+ | Web | ✅ |
325
+
326
+ ## Notes
327
+
328
+ ### Large Files
329
+
330
+ When printing base64 encoded data, large files can lead to app crashes due to memory constraints. For large files, it's recommended to save them to the device first and use `printFile()` instead.
331
+
332
+ ### Web Platform
333
+
334
+ On the web platform:
335
+ - `printWebView()` triggers the browser's native print dialog
336
+ - Other methods create an iframe and print its content
337
+ - Some browsers may have security restrictions on printing certain file types
338
+
339
+ ### Print Styles
340
+
341
+ When printing web content, you can use CSS media queries to customize the print output:
342
+
343
+ ```css
344
+ @media print {
345
+ /* Your print styles here */
346
+ body {
347
+ font-size: 12pt;
348
+ }
349
+ .no-print {
350
+ display: none;
351
+ }
352
+ }
353
+ ```
@@ -0,0 +1,61 @@
1
+ ext {
2
+ junitVersion = project.hasProperty('junitVersion') ? rootProject.ext.junitVersion : '4.13.2'
3
+ androidxAppCompatVersion = project.hasProperty('androidxAppCompatVersion') ? rootProject.ext.androidxAppCompatVersion : '1.6.1'
4
+ androidxJunitVersion = project.hasProperty('androidxJunitVersion') ? rootProject.ext.androidxJunitVersion : '1.1.5'
5
+ androidxEspressoCoreVersion = project.hasProperty('androidxEspressoCoreVersion') ? rootProject.ext.androidxEspressoCoreVersion : '3.5.1'
6
+ androidxDocumentFileVersion = project.hasProperty('androidxDocumentFileVersion') ? rootProject.ext.androidxDocumentFileVersion : '1.0.1'
7
+ androidxPrintVersion = project.hasProperty('androidxPrintVersion') ? rootProject.ext.androidxPrintVersion : '1.0.0'
8
+ }
9
+
10
+ buildscript {
11
+ repositories {
12
+ google()
13
+ mavenCentral()
14
+ }
15
+ dependencies {
16
+ classpath 'com.android.tools.build:gradle:8.2.1'
17
+ }
18
+ }
19
+
20
+ apply plugin: 'com.android.library'
21
+
22
+ android {
23
+ namespace "com.capgo.printer"
24
+ compileSdkVersion project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 34
25
+ defaultConfig {
26
+ minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 22
27
+ targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 34
28
+ versionCode 1
29
+ versionName "1.0.0"
30
+ testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
31
+ }
32
+ buildTypes {
33
+ release {
34
+ minifyEnabled false
35
+ proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
36
+ }
37
+ }
38
+ lintOptions {
39
+ abortOnError false
40
+ }
41
+ compileOptions {
42
+ sourceCompatibility JavaVersion.VERSION_17
43
+ targetCompatibility JavaVersion.VERSION_17
44
+ }
45
+ }
46
+
47
+ repositories {
48
+ google()
49
+ mavenCentral()
50
+ }
51
+
52
+ dependencies {
53
+ implementation fileTree(dir: 'libs', include: ['*.jar'])
54
+ implementation project(':capacitor-android')
55
+ implementation "androidx.appcompat:appcompat:$androidxAppCompatVersion"
56
+ implementation "androidx.documentfile:documentfile:$androidxDocumentFileVersion"
57
+ implementation "androidx.print:print:$androidxPrintVersion"
58
+ testImplementation "junit:junit:$junitVersion"
59
+ androidTestImplementation "androidx.test.ext:junit:$androidxJunitVersion"
60
+ androidTestImplementation "androidx.test.espresso:espresso-core:$androidxEspressoCoreVersion"
61
+ }
@@ -0,0 +1,2 @@
1
+ <manifest xmlns:android="http://schemas.android.com/apk/res/android">
2
+ </manifest>