@nativescript-community/ui-appbar 0.0.0-stage → 1.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.
package/index.ios.js ADDED
@@ -0,0 +1,472 @@
1
+ import { Color, GridLayout, ItemSpec, Page, Utils, View } from '@nativescript/core';
2
+ import { createNativeFormattedText } from '@nativescript-community/ui-core/formatted-text';
3
+ import { createNativeMenu, getNativeIcon } from '@nativescript-community/ui-menu';
4
+ import { AppBarBase, AppBarItem, AppPageSearchContent, notifyBottomItemTap } from './index-common';
5
+ export { AppBarItem, AppPageSearchContent };
6
+ function findScrollView(view) {
7
+ const native = view?.nativeViewProtected;
8
+ if (!native) {
9
+ return null;
10
+ }
11
+ if (native instanceof UIScrollView) {
12
+ return native;
13
+ }
14
+ return native.scrollView instanceof UIScrollView ? native.scrollView : null;
15
+ }
16
+ var BottomItemHandler = /** @class */ (function (_super) {
17
+ __extends(BottomItemHandler, _super);
18
+ function BottomItemHandler() {
19
+ return _super !== null && _super.apply(this, arguments) || this;
20
+ }
21
+ BottomItemHandler.initWithOwnerItem = function (owner, item) {
22
+ var handler = BottomItemHandler.new();
23
+ handler.owner = new WeakRef(owner);
24
+ handler.item = item;
25
+ return handler;
26
+ };
27
+ BottomItemHandler.prototype.tap = function (sender) {
28
+ var _a;
29
+ var bar = (_a = this.owner) === null || _a === void 0 ? void 0 : _a.deref();
30
+ if (bar) {
31
+ notifyBottomItemTap(bar, this.item);
32
+ }
33
+ };
34
+ BottomItemHandler.ObjCExposedMethods = {
35
+ tap: { returns: interop.types.void, params: [interop.types.id] }
36
+ };
37
+ return BottomItemHandler;
38
+ }(NSObject));
39
+ /** iOS 26: the badge of a bar button item (a count, a text, or a dot) */
40
+ function applyBadge(barButtonItem, badge) {
41
+ if (typeof UIBarButtonItemBadge === 'undefined' || !('badge' in barButtonItem)) {
42
+ return;
43
+ }
44
+ const value = badge;
45
+ if (value === undefined || value === null || value === false || value === '') {
46
+ barButtonItem.badge = null;
47
+ }
48
+ else if (value === true) {
49
+ barButtonItem.badge = UIBarButtonItemBadge.indicatorBadge();
50
+ }
51
+ else if (typeof value === 'number') {
52
+ barButtonItem.badge = UIBarButtonItemBadge.badgeWithCount(value);
53
+ }
54
+ else {
55
+ barButtonItem.badge = UIBarButtonItemBadge.badgeWithString(String(value));
56
+ }
57
+ }
58
+ const SEARCH_PLACEMENTS = { automatic: 0, integrated: 1, stacked: 2, integratedCentered: 3, integratedButton: 4 };
59
+ var PassthroughView = /** @class */ (function (_super) {
60
+ __extends(PassthroughView, _super);
61
+ function PassthroughView() {
62
+ return _super !== null && _super.apply(this, arguments) || this;
63
+ }
64
+ // @ts-ignore
65
+ PassthroughView.prototype.hitTestWithEvent = function (point, event) {
66
+ var hit = _super.prototype.hitTestWithEvent.call(this, point, event);
67
+ return hit === this ? null : hit;
68
+ };
69
+ return PassthroughView;
70
+ }(UIView));
71
+ /**
72
+ * Layout for the views anchored to the page (a floating action button, a bottom bar...): use it as the `overlay` of an AppPage.
73
+ * Its empty areas let the touches go through to the content.
74
+ */
75
+ export class AppPageOverlay extends GridLayout {
76
+ constructor() {
77
+ super();
78
+ this.addRow(new ItemSpec(1, 'star'));
79
+ this.addColumn(new ItemSpec(1, 'star'));
80
+ }
81
+ createNativeView() {
82
+ return PassthroughView.new();
83
+ }
84
+ }
85
+ var SearchDelegate = /** @class */ (function (_super) {
86
+ __extends(SearchDelegate, _super);
87
+ function SearchDelegate() {
88
+ return _super !== null && _super.apply(this, arguments) || this;
89
+ }
90
+ SearchDelegate.initWithOwner = function (owner) {
91
+ var delegate = SearchDelegate.new();
92
+ delegate.owner = new WeakRef(owner);
93
+ return delegate;
94
+ };
95
+ SearchDelegate.prototype.updateSearchResultsForSearchController = function (searchController) {
96
+ var _a, _b;
97
+ var bar = (_a = this.owner) === null || _a === void 0 ? void 0 : _a.deref();
98
+ var text = (_b = searchController.searchBar.text) !== null && _b !== void 0 ? _b : '';
99
+ if (bar && bar.searchText !== text) {
100
+ bar.searchText = text;
101
+ bar.notify({ eventName: AppBar.searchChangeEvent, object: bar, text: text });
102
+ }
103
+ };
104
+ SearchDelegate.prototype.searchBarSearchButtonClicked = function (searchBar) {
105
+ var _a, _b;
106
+ var bar = (_a = this.owner) === null || _a === void 0 ? void 0 : _a.deref();
107
+ bar === null || bar === void 0 ? void 0 : bar.notify({ eventName: AppBar.searchSubmitEvent, object: bar, text: (_b = searchBar.text) !== null && _b !== void 0 ? _b : '' });
108
+ };
109
+ SearchDelegate.prototype.searchBarCancelButtonClicked = function (searchBar) {
110
+ var _a;
111
+ var bar = (_a = this.owner) === null || _a === void 0 ? void 0 : _a.deref();
112
+ if (bar) {
113
+ bar.searchText = '';
114
+ bar.notify({ eventName: AppBar.searchCancelEvent, object: bar, text: '' });
115
+ }
116
+ };
117
+ SearchDelegate.ObjCProtocols = [UISearchResultsUpdating, UISearchBarDelegate];
118
+ return SearchDelegate;
119
+ }(NSObject));
120
+ /**
121
+ * iOS: the page `navigationItem` of the navigation controller bar.
122
+ * - `size` medium / large: large title that collapses with the scroll (limit: on a pushed page the inline title is not shown once collapsed, UIKit `Always` mode)
123
+ * - `scrollBehavior`: `lift` separator / shadow only when content scrolls under the bar, `hide` hides the bar when swiping (hidesBarsOnSwipe)
124
+ * - `translucent`: blur when content scrolls under the bar, see through at the top
125
+ * - `scrollTarget`: the scroll view the bar follows (setContentScrollView), by default UIKit finds the first one
126
+ * - `subtitle` and `formattedTitle` (spans): iOS 26 (`subtitle`, `attributedTitle`)
127
+ * iOS 26 gives the bar buttons the Liquid Glass look.
128
+ */
129
+ export class AppBar extends AppBarBase {
130
+ constructor() {
131
+ super(...arguments);
132
+ this._hadFormattedTitle = false;
133
+ this._bottomHandlers = [];
134
+ this._ignoredSafeArea = false;
135
+ this._expandedBarHeight = 0;
136
+ this._inlineTitleShown = false;
137
+ }
138
+ update() {
139
+ super.update();
140
+ this.applyAppBar();
141
+ }
142
+ createBarButtonItem(item) {
143
+ let barButtonItem;
144
+ if (item instanceof AppBarItem && item.menu?.length && !item.actionView) {
145
+ // the bar button shows a native menu when tapped
146
+ const menu = createNativeMenu(item.menu);
147
+ const image = item.icon ? getNativeIcon(item.icon) : null;
148
+ barButtonItem = image ? UIBarButtonItem.alloc().initWithImageMenu(image, menu) : UIBarButtonItem.alloc().initWithTitleMenu(item.text + '', menu);
149
+ barButtonItem.accessibilityLabel = item.text;
150
+ }
151
+ else {
152
+ // @ts-ignore
153
+ barButtonItem = super.createBarButtonItem(item);
154
+ }
155
+ if (item instanceof AppBarItem && barButtonItem) {
156
+ applyBadge(barButtonItem, item.badge);
157
+ }
158
+ if (item instanceof AppBarItem && item.prominent && barButtonItem && 'style' in barButtonItem) {
159
+ // UIBarButtonItemStylePlain = 0, Done / prominent = 2
160
+ barButtonItem.style = 2;
161
+ }
162
+ return barButtonItem;
163
+ }
164
+ applyAppBar() {
165
+ const page = this.page;
166
+ const viewController = page?.ios;
167
+ const navigationItem = viewController?.navigationItem;
168
+ const navController = viewController?.navigationController;
169
+ if (!navigationItem || !navController) {
170
+ return;
171
+ }
172
+ const navigationBar = navController.navigationBar;
173
+ const size = this.size || 'small';
174
+ const behavior = this.scrollBehavior || 'none';
175
+ // large title. `Automatic` collapses to an inline title but follows the state of the previous page: it is only large on the root page of the Frame.
176
+ // `Always` shows the large title on a pushed page, but UIKit never shows the inline title once collapsed.
177
+ const isRoot = navController.viewControllers.indexOfObject(viewController) === 0;
178
+ if (size !== 'small') {
179
+ navigationBar.prefersLargeTitles = true;
180
+ }
181
+ navigationItem.largeTitleDisplayMode =
182
+ size === 'small' ? 2 /* UINavigationItemLargeTitleDisplayMode.Never */ : isRoot ? 0 /* UINavigationItemLargeTitleDisplayMode.Automatic */ : 1 /* UINavigationItemLargeTitleDisplayMode.Always */;
183
+ // appearances: one for the bar when content scrolls under it (standard) and one at the top (scroll edge)
184
+ const base = (navigationBar.standardAppearance ?? UINavigationBarAppearance.new()).copy();
185
+ const standard = base.copy();
186
+ const edge = base.copy();
187
+ if (this.translucent) {
188
+ // the content scrolls under the bar: a blur tinted with the color of the bar, at the top too
189
+ const barColor = standard.backgroundColor;
190
+ const tinted = barColor ? barColor.colorWithAlphaComponent(0.7) : null;
191
+ for (const appearance of [standard, edge]) {
192
+ appearance.backgroundEffect = UIBlurEffect.effectWithStyle(10 /* UIBlurEffectStyle.SystemChromeMaterial */);
193
+ appearance.backgroundColor = tinted;
194
+ }
195
+ edge.shadowColor = UIColor.clearColor;
196
+ }
197
+ else if (behavior === 'lift') {
198
+ edge.shadowColor = UIColor.clearColor;
199
+ }
200
+ // iOS 26: the subtitle and the large title have their own text attributes: same as the title
201
+ for (const appearance of [standard, edge]) {
202
+ const attributes = appearance.titleTextAttributes;
203
+ if (attributes) {
204
+ for (const key of ['subtitleTextAttributes', 'largeSubtitleTextAttributes']) {
205
+ if (key in appearance) {
206
+ appearance[key] = attributes;
207
+ }
208
+ }
209
+ // the large title has the color of the title
210
+ const color = attributes.objectForKey(NSForegroundColorAttributeName);
211
+ if (color) {
212
+ const large = NSMutableDictionary.dictionaryWithDictionary((appearance.largeTitleTextAttributes ?? NSDictionary.new()));
213
+ large.setObjectForKey(color, NSForegroundColorAttributeName);
214
+ appearance.largeTitleTextAttributes = large;
215
+ }
216
+ }
217
+ }
218
+ navigationItem.standardAppearance = standard;
219
+ navigationItem.compactAppearance = standard;
220
+ navigationItem.scrollEdgeAppearance = edge;
221
+ // hide on swipe
222
+ navController.hidesBarsOnSwipe = behavior === 'hide';
223
+ // title with spans and subtitle (iOS 26)
224
+ if (this.formattedTitle && !this.titleView) {
225
+ const attributed = createNativeFormattedText(this.formattedTitle);
226
+ if (navigationItem.respondsToSelector('setAttributedTitle:')) {
227
+ navigationItem.attributedTitle = attributed;
228
+ }
229
+ else {
230
+ const label = UILabel.new();
231
+ label.attributedText = attributed;
232
+ label.sizeToFit();
233
+ navigationItem.titleView = label;
234
+ }
235
+ this._hadFormattedTitle = true;
236
+ }
237
+ else if (this._hadFormattedTitle) {
238
+ // clearing the attributed title also clears the title: set it again
239
+ this._hadFormattedTitle = false;
240
+ if (navigationItem.respondsToSelector('setAttributedTitle:')) {
241
+ navigationItem.attributedTitle = null;
242
+ }
243
+ navigationItem.titleView = this.titleView?.ios ?? null;
244
+ navigationItem.title = this.title;
245
+ }
246
+ if (navigationItem.respondsToSelector('setSubtitle:')) {
247
+ navigationItem.subtitle = this.subtitle ?? null;
248
+ }
249
+ this.applyOverflowSafeArea();
250
+ this.applyBottomItems(viewController, navController);
251
+ this.applySearch(navigationItem, behavior);
252
+ this.applyScrollTarget(viewController);
253
+ }
254
+ /** the bottom toolbar of the navigation controller (Liquid Glass buttons on iOS 26) */
255
+ applyBottomItems(viewController, navController) {
256
+ const items = this.bottomItems;
257
+ if (!items?.length) {
258
+ if (!navController.toolbarHidden) {
259
+ navController.setToolbarHiddenAnimated(true, false);
260
+ }
261
+ viewController.setToolbarItemsAnimated(null, false);
262
+ this._bottomHandlers = [];
263
+ return;
264
+ }
265
+ const handlers = [];
266
+ const badges = [];
267
+ const barButtonItems = NSMutableArray.new();
268
+ for (const item of items) {
269
+ if (item.spacer) {
270
+ barButtonItems.addObject(UIBarButtonItem.alloc().initWithBarButtonSystemItemTargetAction(5 /* UIBarButtonSystemItem.FlexibleSpace */, null, null));
271
+ continue;
272
+ }
273
+ const handler = BottomItemHandler.initWithOwnerItem(this, item);
274
+ handlers.push(handler);
275
+ const image = item.icon ? getNativeIcon(item.icon) : null;
276
+ const barButtonItem = image
277
+ ? UIBarButtonItem.alloc().initWithImageStyleTargetAction(image, 0 /* UIBarButtonItemStyle.Plain */, handler, 'tap')
278
+ : UIBarButtonItem.alloc().initWithTitleStyleTargetAction(item.text + '', 0 /* UIBarButtonItemStyle.Plain */, handler, 'tap');
279
+ barButtonItem.accessibilityLabel = item.text;
280
+ badges.push([barButtonItem, item.badge]);
281
+ barButtonItems.addObject(barButtonItem);
282
+ }
283
+ // the handlers must stay alive
284
+ this._bottomHandlers = handlers;
285
+ viewController.setToolbarItemsAnimated(barButtonItems, false);
286
+ navController.setToolbarHiddenAnimated(false, false);
287
+ // the badge is set once the items are in the toolbar
288
+ badges.forEach(([barButtonItem, badge]) => applyBadge(barButtonItem, badge));
289
+ }
290
+ /**
291
+ * translucent: the page does not shrink its content to the safe area (the NativeScript Page places its content below the bar):
292
+ * the scrolling view starts at the top of the page, under the bar. UIKit adds the safe area to its content inset,
293
+ * so the first rows start below the bar and the next ones scroll under the blur.
294
+ * Works when the scrolling view is the content of the page.
295
+ */
296
+ applyOverflowSafeArea() {
297
+ const page = this.page;
298
+ const wanted = this.translucent;
299
+ if (wanted !== this._ignoredSafeArea) {
300
+ this._ignoredSafeArea = wanted;
301
+ page.iosIgnoreSafeArea = wanted;
302
+ page.requestLayout();
303
+ page.ios.view.setNeedsLayout();
304
+ }
305
+ }
306
+ applySearch(navigationItem, behavior) {
307
+ if (!this.searchable) {
308
+ navigationItem.searchController = null;
309
+ return;
310
+ }
311
+ if (!this._searchController) {
312
+ const controller = UISearchController.alloc().initWithSearchResultsController(null);
313
+ this._searchDelegate = SearchDelegate.initWithOwner(this);
314
+ controller.searchResultsUpdater = this._searchDelegate;
315
+ controller.searchBar.delegate = this._searchDelegate;
316
+ controller.obscuresBackgroundDuringPresentation = false;
317
+ this._searchController = controller;
318
+ }
319
+ const searchBar = this._searchController.searchBar;
320
+ searchBar.placeholder = this.searchHint ?? null;
321
+ // the field follows the color of the bar
322
+ const color = this.color instanceof Color ? this.color : this.color ? new Color(this.color) : null;
323
+ const field = searchBar.searchTextField;
324
+ if (color && field) {
325
+ field.textColor = color.ios;
326
+ field.tintColor = color.ios;
327
+ field.leftView && (field.leftView.tintColor = color.ios);
328
+ if (this.searchHint) {
329
+ field.attributedPlaceholder = NSAttributedString.alloc().initWithStringAttributes(this.searchHint, {
330
+ [NSForegroundColorAttributeName]: new Color(150, color.r, color.g, color.b).ios
331
+ });
332
+ }
333
+ }
334
+ // the search bar stays visible unless the bar scrolls away
335
+ navigationItem.hidesSearchBarWhenScrolling = behavior === 'hide';
336
+ if ('preferredSearchBarPlacement' in navigationItem) {
337
+ // iOS 16+: the search bar under the title, as with large titles
338
+ navigationItem.preferredSearchBarPlacement = SEARCH_PLACEMENTS[this.searchPlacement || 'stacked'] ?? 2;
339
+ }
340
+ navigationItem.searchController = this._searchController;
341
+ this.page.ios.definesPresentationContext = true;
342
+ }
343
+ /**
344
+ * A large title on a pushed page uses the UIKit `Always` mode, which never shows the inline title once collapsed:
345
+ * a title view is shown while the bar is collapsed (the height of the bar tells).
346
+ */
347
+ observeInlineTitle(target) {
348
+ const viewController = this.page?.ios;
349
+ if (!viewController || this._inlineTitleTarget === target) {
350
+ return;
351
+ }
352
+ if (this._inlineTitleTarget) {
353
+ this._inlineTitleTarget.off('scroll', this._inlineTitleListener);
354
+ }
355
+ this._inlineTitleTarget = target;
356
+ this._inlineTitleListener = () => this.updateInlineTitle();
357
+ target.on('scroll', this._inlineTitleListener);
358
+ }
359
+ updateInlineTitle() {
360
+ const viewController = this.page?.ios;
361
+ const navigationItem = viewController?.navigationItem;
362
+ const navigationBar = viewController?.navigationController?.navigationBar;
363
+ if (!navigationItem || !navigationBar || this.titleView || this.size === 'small' || navigationItem.largeTitleDisplayMode !== 1 /* UINavigationItemLargeTitleDisplayMode.Always */) {
364
+ return;
365
+ }
366
+ const height = navigationBar.frame.size.height;
367
+ this._expandedBarHeight = Math.max(this._expandedBarHeight, height);
368
+ const collapsed = height < this._expandedBarHeight - 20;
369
+ if (collapsed === this._inlineTitleShown) {
370
+ return;
371
+ }
372
+ this._inlineTitleShown = collapsed;
373
+ if (!collapsed) {
374
+ navigationItem.titleView = null;
375
+ return;
376
+ }
377
+ const label = UILabel.new();
378
+ label.textAlignment = 1 /* NSTextAlignment.Center */;
379
+ const attributes = (navigationItem.standardAppearance ?? navigationBar.standardAppearance)?.titleTextAttributes;
380
+ const text = NSMutableAttributedString.new();
381
+ const title = this.formattedTitle ? createNativeFormattedText(this.formattedTitle) : NSAttributedString.alloc().initWithStringAttributes(this.title ?? '', attributes);
382
+ text.appendAttributedString(title);
383
+ label.attributedText = text;
384
+ label.sizeToFit();
385
+ navigationItem.titleView = label;
386
+ }
387
+ applyScrollTarget(viewController) {
388
+ const target = this.scrollTarget;
389
+ if (!target) {
390
+ return;
391
+ }
392
+ const scrollView = findScrollView(target);
393
+ if (scrollView) {
394
+ viewController.setContentScrollViewForEdge(scrollView, 1 /* NSDirectionalRectEdge.Top */);
395
+ this.observeInlineTitle(target);
396
+ }
397
+ else if (!this._scrollTargetLoadedHandler) {
398
+ // not created yet
399
+ this._scrollTargetLoadedHandler = () => {
400
+ target.off('loaded', this._scrollTargetLoadedHandler);
401
+ this._scrollTargetLoadedHandler = null;
402
+ this.update();
403
+ };
404
+ target.on('loaded', this._scrollTargetLoadedHandler);
405
+ }
406
+ }
407
+ }
408
+ /**
409
+ * iOS: the navigation controller of the Frame already owns the bar (large title, blur, scroll edge effect): the page is a regular Page.
410
+ */
411
+ export class AppPage extends Page {
412
+ constructor() {
413
+ super(...arguments);
414
+ this.scrollBehavior = 'none';
415
+ }
416
+ /** views anchored to the page (a FAB, a bottom bar...) instead of the scrolling content: they are laid out over the content */
417
+ get overlay() {
418
+ return this._overlay;
419
+ }
420
+ set overlay(value) {
421
+ if (this._overlay === value) {
422
+ return;
423
+ }
424
+ if (this._overlay) {
425
+ this._removeView(this._overlay);
426
+ }
427
+ this._overlay = value;
428
+ if (value) {
429
+ this._addView(value);
430
+ }
431
+ }
432
+ _addChildFromBuilder(name, value) {
433
+ if (value instanceof AppPageOverlay) {
434
+ this.overlay = value;
435
+ }
436
+ else if (value instanceof AppPageSearchContent) {
437
+ // Android only (full screen search)
438
+ }
439
+ else {
440
+ super._addChildFromBuilder(name, value);
441
+ }
442
+ }
443
+ eachChildView(callback) {
444
+ super.eachChildView(callback);
445
+ if (this._overlay) {
446
+ callback(this._overlay);
447
+ }
448
+ }
449
+ onMeasure(widthMeasureSpec, heightMeasureSpec) {
450
+ super.onMeasure(widthMeasureSpec, heightMeasureSpec);
451
+ if (this._overlay) {
452
+ const width = Utils.layout.getMeasureSpecSize(widthMeasureSpec);
453
+ const height = Utils.layout.getMeasureSpecSize(heightMeasureSpec);
454
+ View.measureChild(this, this._overlay, Utils.layout.makeMeasureSpec(width, Utils.layout.EXACTLY), Utils.layout.makeMeasureSpec(height, Utils.layout.EXACTLY));
455
+ }
456
+ }
457
+ onLayout(left, top, right, bottom) {
458
+ super.onLayout(left, top, right, bottom);
459
+ if (this._overlay) {
460
+ // inside the safe area (also when the content ignores it)
461
+ const safeArea = this.nativeViewProtected.safeAreaInsets;
462
+ const insets = {
463
+ left: Utils.layout.toDevicePixels(safeArea.left),
464
+ top: Utils.layout.toDevicePixels(safeArea.top),
465
+ right: Utils.layout.toDevicePixels(safeArea.right),
466
+ bottom: Utils.layout.toDevicePixels(safeArea.bottom)
467
+ };
468
+ View.layoutChild(this, this._overlay, insets.left, insets.top, right - insets.right, bottom - insets.bottom);
469
+ }
470
+ }
471
+ }
472
+ //# sourceMappingURL=index.ios.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.ios.js","sourceRoot":"","sources":["../../src/ui-appbar/index.ios.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,UAAU,EAAE,QAAQ,EAAE,IAAI,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,oBAAoB,CAAC;AACpF,OAAO,EAAE,yBAAyB,EAAE,MAAM,gDAAgD,CAAC;AAC3F,OAAO,EAAE,gBAAgB,EAAE,aAAa,EAAE,MAAM,iCAAiC,CAAC;AAClF,OAAO,EAAE,UAAU,EAAoB,UAAU,EAA6E,oBAAoB,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAC;AAChM,OAAO,EAAoB,UAAU,EAA6E,oBAAoB,EAAE,CAAC;AAEzI,SAAS,cAAc,CAAC,IAAU;IAC9B,MAAM,MAAM,GAAG,IAAI,EAAE,mBAAmB,CAAC;IACzC,IAAI,CAAC,MAAM,EAA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,GAAG,CAAC;gBAC9C,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC,cAAc,CAAC,QAAQ,CAAC,KAAK,CAAC;gBAClD,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,cAAc,CAAC,QAAQ,CAAC,MAAM,CAAC;aACvD,CAAC;YACF,IAAI,CAAC,WAAW,CAAC,IAAI,EAAE,IAAI,CAAC,QAAQ,EAAE,MAAM,CAAC,IAAI,EAAE,MAAM,CAAC,GAAG,EAAE,KAAK,GAAG,MAAM,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC;QACjH,CAAC;IACL,CAAC;CACJ"}
package/package.json CHANGED
@@ -1,6 +1,50 @@
1
1
  {
2
- "name": "@nativescript-community/ui-appbar",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
2
+ "name": "@nativescript-community/ui-appbar",
3
+ "version": "1.0.0",
4
+ "description": "App bar and page: Material top app bar (collapsing, lift on scroll) on Android, native navigation bar on iOS",
5
+ "main": "./index",
6
+ "sideEffects": false,
7
+ "typings": "./index.d.ts",
8
+ "scripts": {
9
+ "tsc": "cpy '**/*.d.ts' '../../packages/ui-appbar' --parents --cwd=../../src/ui-appbar && tsc --build",
10
+ "readme": "readme generate -c ../../tools/readme/blueprint.json",
11
+ "build": "npm run tsc && npm run readme",
12
+ "build.watch": "npm run tsc -- -w",
13
+ "build.all": "npm run build",
14
+ "clean": "bin/rimraf ./*.d.ts ./*.js ./*.js.map ./*.tsbuildinfo ./*.mjs ./*.mjs.map ./angular ./svelte ./vue* ./react"
15
+ },
16
+ "nativescript": {
17
+ "platforms": {
18
+ "android": "6.2.0",
19
+ "ios": "6.2.0"
20
+ }
21
+ },
22
+ "keywords": [
23
+ "NativeScript",
24
+ "JavaScript",
25
+ "Android",
26
+ "iOS"
27
+ ],
28
+ "author": {
29
+ "name": "Martin Guillon",
30
+ "email": "martin@akylas.fr"
31
+ },
32
+ "bugs": {
33
+ "url": "https://github.com/nativescript-community/ui-material-components/issues"
34
+ },
35
+ "license": "Apache-2.0",
36
+ "publishConfig": {
37
+ "access": "public"
38
+ },
39
+ "homepage": "https://github.com/nativescript-community/ui-material-components",
40
+ "repository": {
41
+ "type": "git",
42
+ "url": "https://github.com/nativescript-community/ui-material-components/tree/master/packages/ui-appbar"
43
+ },
44
+ "readmeFilename": "README.md",
45
+ "dependencies": {
46
+ "@nativescript-community/ui-core": "^1.0.0",
47
+ "@nativescript-community/ui-menu": "^1.0.0"
48
+ },
49
+ "gitHead": "237dd97d2b9e0f62ea9d9810169bb800dd531f7b"
50
+ }
@@ -0,0 +1,6 @@
1
+
2
+ dependencies {
3
+ def androidXMaterial = project.hasProperty("androidXMaterial") ? project.androidXMaterial : "1.14.0"
4
+
5
+ implementation "com.google.android.material:material:$androidXMaterial"
6
+ }
@@ -0,0 +1,48 @@
1
+ {
2
+ "uses": [
3
+ "android.content.res:ColorStateList",
4
+ "android.content:Context",
5
+ "android.graphics:Color",
6
+ "android.text:Editable",
7
+ "android.text:TextWatcher",
8
+ "android.util:TypedValue",
9
+ "android.view:Gravity",
10
+ "android.view:LayoutInflater",
11
+ "android.view:MenuItem",
12
+ "android.view:MenuItem.OnActionExpandListener",
13
+ "android.view:View",
14
+ "android.view:View.OnLayoutChangeListener",
15
+ "android.view:ViewGroup",
16
+ "android.view:WindowManager.LayoutParams",
17
+ "android.widget:EditText",
18
+ "android.widget:ImageView",
19
+ "android.widget:TextView.OnEditorActionListener",
20
+ "androidx.appcompat.widget:SearchView",
21
+ "androidx.appcompat.widget:SearchView.OnQueryTextListener",
22
+ "androidx.appcompat.widget:Toolbar",
23
+ "androidx.appcompat.widget:Toolbar.OnMenuItemClickListener",
24
+ "androidx.coordinatorlayout.widget:CoordinatorLayout",
25
+ "androidx.core.content:ContextCompat",
26
+ "androidx.core.graphics.drawable:DrawableCompat",
27
+ "androidx.core.graphics:ColorUtils",
28
+ "androidx.core.view:MenuItemCompat",
29
+ "androidx.core.view:OnApplyWindowInsetsListener",
30
+ "androidx.core.view:ViewCompat",
31
+ "androidx.core.view:WindowInsetsCompat",
32
+ "androidx.core.view:WindowInsetsCompat.Type",
33
+ "com.google.android.material.appbar:AppBarLayout",
34
+ "com.google.android.material.appbar:AppBarLayout.LayoutParams",
35
+ "com.google.android.material.appbar:AppBarLayout.LiftOnScrollListener",
36
+ "com.google.android.material.appbar:CollapsingToolbarLayout",
37
+ "com.google.android.material.appbar:CollapsingToolbarLayout.LayoutParams",
38
+ "com.google.android.material.appbar:MaterialToolbar",
39
+ "com.google.android.material.badge:BadgeDrawable",
40
+ "com.google.android.material.badge:BadgeUtils",
41
+ "com.google.android.material.bottomappbar:BottomAppBar",
42
+ "com.google.android.material.color:MaterialColors",
43
+ "com.google.android.material.search:SearchBar",
44
+ "com.google.android.material.search:SearchView",
45
+ "com.google.android.material.search:SearchView.TransitionListener",
46
+ "com.google.android.material.shape:MaterialShapeDrawable"
47
+ ]
48
+ }
@@ -0,0 +1,7 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <com.google.android.material.appbar.CollapsingToolbarLayout xmlns:android="http://schemas.android.com/apk/res/android"
3
+ xmlns:app="http://schemas.android.com/apk/res-auto"
4
+ style="?attr/collapsingToolbarLayoutLargeStyle"
5
+ android:layout_width="match_parent"
6
+ android:layout_height="?attr/collapsingToolbarLayoutLargeSize"
7
+ app:layout_scrollFlags="scroll|exitUntilCollapsed" />
@@ -0,0 +1,7 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <com.google.android.material.appbar.CollapsingToolbarLayout xmlns:android="http://schemas.android.com/apk/res/android"
3
+ xmlns:app="http://schemas.android.com/apk/res-auto"
4
+ style="?attr/collapsingToolbarLayoutMediumStyle"
5
+ android:layout_width="match_parent"
6
+ android:layout_height="?attr/collapsingToolbarLayoutMediumSize"
7
+ app:layout_scrollFlags="scroll|exitUntilCollapsed" />
@@ -0,0 +1,11 @@
1
+ {
2
+ "uses": [
3
+ "CoreFoundation*",
4
+ "CoreGraphics*",
5
+ "Darwin*",
6
+ "Foundation*",
7
+ "ObjectiveC*",
8
+ "QuartzCore*",
9
+ "UIKit*"
10
+ ]
11
+ }
@@ -0,0 +1,2 @@
1
+ /** registers `<appPage>` and `<appBar>` */
2
+ export declare function register(): void;