Skip to content

Instantly share code, notes, and snippets.

🇵🇱
 🇵🇱

Marcin Szałek MarcinusX

🇵🇱
 🇵🇱
Block or report user

Report or block MarcinusX

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@MarcinusX
MarcinusX / main.dart
Created Mar 21, 2019
Ripple effect transition
View main.dart
import 'package:flutter/material.dart';
import 'package:rect_getter/rect_getter.dart';
void main() => runApp(MyApp());
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Fab overlay transition',
View BMI Calculator - height
https://marcinszalek.pl/tag/bmi-calculator/
@MarcinusX
MarcinusX / card_title.dart
Last active Sep 4, 2018
BMI Calculator - Weight
View card_title.dart
import 'package:flutter/material.dart';
const TextStyle _titleStyle = TextStyle(
fontSize: 16.0,
fontWeight: FontWeight.w500,
color: Color.fromRGBO(14, 24, 35, 1.0),
);
const TextStyle _subtitleStyle = TextStyle(
fontSize: 8.0,
View setValidationInOfficeJs.ts
public async setValidation(source: Excel.Range, target: Excel.Range) {
Excel.run(function (context) {
return context.sync().then(() => {
target.dataValidation.rule = {
list: {
inCellDropDown: true,
source: source.values.toString(),
}
};
return context.sync();
@MarcinusX
MarcinusX / officeCustomProperties.md
Created Jul 13, 2018
Explanation on sharing custom properties between Office 2013 and Office Online
View officeCustomProperties.md

Office VSTO + jsAPI custom properties manual

Explanation

So far in VSTO we were saving properties separately in every Worksheet. JavaScript API for Office doesn't have such function (as of 13/07/2018). Instead we can save those properties in Workbook's documentProperties which are accessable both in VSTO and JS.

Note: CP means CustomProperties (too long to write every time)

JS (actually TS):

Docs

Loading

There is a bug with loading CP, so in order to load them we have to ensure that the list is not empty:

@MarcinusX
MarcinusX / infinite_listview.dart
Created Apr 16, 2018
This is source code for a blog post.
View infinite_listview.dart
import 'dart:async';
import 'package:flutter/material.dart';
void main() => runApp(new MyApp());
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return new MaterialApp(
@MarcinusX
MarcinusX / Sliver AppBar
Created Mar 30, 2018
Sliver AppBar case study created for post on www.marcinszalek.pl
View Sliver AppBar
import 'package:flutter/material.dart';
void main() => runApp(new MyApp());
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return new MaterialApp(
title: 'Sliver Fab Example',
theme: new ThemeData(
@MarcinusX
MarcinusX / Scala test presentation
Last active Mar 13, 2018
Tests from college scala test presentation
View Scala test presentation
//
// Presentation: https://goo.gl/GhYvKy
// Dependency: libraryDependencies += "org.scalatest" %% "scalatest" % "3.0.5" % "test"
//
import org.scalatest.{FunSpec, FunSuite}
object Calculator {
@MarcinusX
MarcinusX / main.dart
Created Nov 21, 2017
Test for FirebaseUser update
View main.dart
import 'dart:async';
import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart';
void main() {
runApp(new MyApp());
}
class MyApp extends StatelessWidget {
You can’t perform that action at this time.