This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Copyright 2014 The Flutter Authors. All rights reserved. | |
// Use of this source code is governed by a BSD-style license that can be | |
// found in the LICENSE file. | |
import 'package:flutter/cupertino.dart'; | |
import 'package:flutter/services.dart'; | |
// Offset from offscreen below to stopping below the top of the screen. | |
final Animatable<Offset> _kBottomUpTween = Tween<Offset>( | |
begin: const Offset(0.0, 1.0), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'dart:convert'; | |
import 'dart:io'; | |
import 'package:googleapis/androidpublisher/v3.dart'; | |
import 'package:googleapis_auth/auth_io.dart'; | |
const _flutterPath = 'C:/flutter/bin/flutter.bat'; | |
const _workingDirectory = 'c:/users/x/projects/project_root_dir'; | |
const _credentialsFile = 'c:/your_service_account_path/profile-e045e9cef64e.json'; | |
const _packageName = 'com.zzz.xxx.yyy'; | |
const _whatsNew = 'This is a test of the upload script.'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
TextField(placeholder, text:$event.title, axis: Axis.vertical) | |
.keyboardType(.default) | |
.focused($textFieldFocus, equals:controlId) | |
// When newline is detected, create a new item (or delete if it's empty) | |
// We'd do this in onKeyPress(.return) but that's only for hardware keyboards | |
.lineLimit(100, reservesSpace: false) | |
.overlay(alignment: Alignment(horizontal:.leading, vertical: .center)) { | |
GeometryReader { proxy in |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:cupertino_calendar_picker/cupertino_calendar_picker.dart'; | |
import 'package:flutter/cupertino.dart'; | |
import 'package:flutter/material.dart'; | |
void main() { | |
runApp(const CupertinoApp( | |
localizationsDelegates: [ | |
DefaultWidgetsLocalizations.delegate, | |
DefaultCupertinoLocalizations.delegate, | |
DefaultMaterialLocalizations.delegate, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
import SwiftUI | |
import UIKit | |
extension UIBlurEffect { | |
public static func variableBlurEffect(radius: Double, imageMask: UIImage) -> UIBlurEffect? { | |
let methodType = (@convention(c) (AnyClass, Selector, Double, UIImage) -> UIBlurEffect).self | |
let selectorName = ["imageMask:", "effectWithVariableBlurRadius:"].reversed().joined() | |
let selector = NSSelectorFromString(selectorName) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import SwiftUI | |
public struct ValuePicker<SelectionValue: Hashable, Content: View>: View { | |
private let title: LocalizedStringKey | |
private let selection: Binding<SelectionValue> | |
private let content: Content | |
public init( | |
_ title: LocalizedStringKey, | |
selection: Binding<SelectionValue>, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import SwiftUI | |
struct PullToRefreshView: View | |
{ | |
private static let minRefreshTimeInterval = TimeInterval(0.2) | |
private static let triggerHeight = CGFloat(100) | |
private static let indicatorHeight = CGFloat(100) | |
private static let fullHeight = triggerHeight + indicatorHeight | |
let backgroundColor: Color |
NewerOlder