From b41d0fb919bb2ffdc4149071d41141861ff9fd7f Mon Sep 17 00:00:00 2001 From: peron Date: Tue, 23 Jan 2024 23:04:00 +0000 Subject: [PATCH] feat: selectable code --- lib/widgets/code_element.dart | 4 ++-- pubspec.lock | 19 ++++++++++++++++++- pubspec.yaml | 6 +++++- 3 files changed, 25 insertions(+), 4 deletions(-) diff --git a/lib/widgets/code_element.dart b/lib/widgets/code_element.dart index a8a8d85..265f371 100644 --- a/lib/widgets/code_element.dart +++ b/lib/widgets/code_element.dart @@ -1,6 +1,6 @@ import 'package:flutter/material.dart'; -import 'package:flutter_highlight/flutter_highlight.dart'; -import 'package:flutter_highlight/themes/atom-one-dark.dart'; +import 'package:flutter_highlighter/flutter_highlighter.dart'; +import 'package:flutter_highlighter/themes/atom-one-dark.dart'; import 'package:google_fonts/google_fonts.dart'; import 'package:sydney_webui/utils/copy.dart'; import 'package:sydney_webui/utils/string.dart'; diff --git a/pubspec.lock b/pubspec.lock index d9b91b3..55892bf 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -119,13 +119,22 @@ packages: source: sdk version: "0.0.0" flutter_highlight: - dependency: "direct main" + dependency: transitive description: name: flutter_highlight sha256: "7b96333867aa07e122e245c033b8ad622e4e3a42a1a2372cbb098a2541d8782c" url: "https://pub.dev" source: hosted version: "0.7.0" + flutter_highlighter: + dependency: "direct main" + description: + path: flutter_highlighter + ref: master + resolved-ref: "9a2b566f0a59fcd414ff5031ccbf0ff1d101f962" + url: "https://github.com/predatorx7/highlight.git" + source: git + version: "0.1.1" flutter_lints: dependency: "direct dev" description: @@ -200,6 +209,14 @@ packages: url: "https://pub.dev" source: hosted version: "0.7.0" + highlighter: + dependency: transitive + description: + name: highlighter + sha256: "92180c72b9da8758e1acf39a45aa305a97dcfe2fdc8f3d1d2947c23f2772bfbc" + url: "https://pub.dev" + source: hosted + version: "0.1.1" http: dependency: transitive description: diff --git a/pubspec.yaml b/pubspec.yaml index af26eed..3f7d43f 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -39,7 +39,11 @@ dependencies: share_plus: markdown: markdown_widget: - flutter_highlight: + flutter_highlighter: + git: + url: https://github.com/predatorx7/highlight.git + path: flutter_highlighter + ref: master flutter_math_fork: dev_dependencies: