- todos_screen.dart@62 todos list is updated within the
State<TodosScreen>
, but failure to callsetState
method does not update the UI. Could be solved by wrapping line 62 in asetState
function call. - The Edit Todo flow opens a selected Todo item on a new screen and "awaits" on the edited result. If the user never clicks "Submit" in the editing screen, null will be returned as the value of edited Todo and
NetworkClient.updateTodo(null)
will be executed (the method is not null-safe), resulting in aNoSuchMethodError
exception. We should not be attempting to update Todo if the user did not perform any changes; so we should only callupdateTodo
andshowSnackBar
if the edited todo is not null. - networkClient.dart@34 creating a new Todo constructs request body inline. Looks like "titles" is a typo, and may have the incorrect body structure (should consult with POST API docs). Should ideally be using a model along with its
toMap
function, so
This file contains 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
using UnityEngine; | |
/** | |
* Avoid deserializing this class and those derived from it, | |
* as only Unity can instantiate Scriptable Objects - constructor call during | |
* deserialization is not allowed. | |
**/ | |
public abstract class QuestSO: ScriptableObject | |
{ | |
[SerializeField] |
This file contains 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
using System; | |
using System.Linq; | |
using UnityEngine; | |
using CI.QuickSave.Core.Storage; | |
/** | |
* Central place for triggering game saving & loading. | |
* Classes using [QuickSave] package will end up writing files at [Application.persistentDataPath]: | |
* MacOS: ~/Library/Application\ Support/DefaultCompany/<productname>/QuickSave | |
* Windows: %userprofile%\AppData\LocalLow\<companyname>\<productname> |
This file contains 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
using System; | |
using Newtonsoft.Json; | |
using UnityEngine; | |
[Serializable] | |
public class MeetQuest : Quest | |
{ | |
[JsonProperty("meetPedestriansAmount")] | |
public int meetPedestriansAmount; |
This file contains 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
name: Acquire activation file | |
on: | |
workflow_dispatch: {} | |
jobs: | |
activation: | |
name: Request manual activation file 🔑 | |
runs-on: ubuntu-latest | |
steps: | |
# Request manual activation file | |
- name: Request manual activation file |
This file contains 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:io'; | |
import 'package:flutter/cupertino.dart'; | |
import 'package:flutter/material.dart'; | |
import 'package:flutter/services.dart'; | |
import 'package:intro_slider/dot_animation_enum.dart'; | |
import 'package:intro_slider/list_rtl_language.dart'; | |
import 'package:intro_slider/scrollbar_behavior_enum.dart'; | |
import 'package:intro_slider/slide_object.dart'; |
This file contains 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:ui'; | |
extension HexColor on Color { | |
/// String is in the format "aabbcc" or "ffaabbcc" with an optional leading "#". | |
static Color fromHex(String hexString) { | |
final buffer = StringBuffer(); | |
if (hexString.length == 6 || hexString.length == 7) buffer.write('ff'); | |
buffer.write(hexString.replaceFirst('#', '')); | |
return Color(int.parse(buffer.toString(), radix: 16)); | |
} |
This file contains 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:universal_html/js.dart' as js; | |
import 'package:universal_html/html.dart' as html; | |
void example() { | |
_enterFullscreen(html.document.documentElement); | |
_exitFullscreen(html.document); | |
} | |
/// Flutter Web: Enter Fullscreen on Firefox, Chrome, Opera, Safari, etc. | |
/// Based on https://stackoverflow.com/questions/29714889/how-to-request-fullscreen-in-compiled-dart |