mirror of
https://github.com/SyncrowIOT/web.git
synced 2025-07-10 07:07:19 +00:00
37 lines
1.2 KiB
Dart
37 lines
1.2 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'color_manager.dart';
|
|
|
|
InputDecoration? textBoxDecoration({bool suffixIcon = false}) => InputDecoration(
|
|
focusColor: ColorsManager.grayColor,
|
|
suffixIcon:suffixIcon? const Icon(Icons.search):null,
|
|
hintText: 'Search',
|
|
filled: true, // Enable background filling
|
|
fillColor: Colors.grey.shade200, // Set the background color
|
|
border: OutlineInputBorder(
|
|
borderRadius: BorderRadius.circular(15), // Add border radius
|
|
borderSide: BorderSide.none, // Remove the underline
|
|
),
|
|
enabledBorder: OutlineInputBorder(
|
|
borderRadius: BorderRadius.circular(15), // Add border radius
|
|
borderSide: BorderSide.none, // Remove the underline
|
|
),
|
|
focusedBorder: OutlineInputBorder(
|
|
borderRadius: BorderRadius.circular(15), // Add border radius
|
|
borderSide: BorderSide.none, // Remove the underline
|
|
),
|
|
);
|
|
|
|
|
|
|
|
Decoration containerDecoration = BoxDecoration(
|
|
boxShadow: [
|
|
BoxShadow(
|
|
color: Colors.grey.withOpacity(0.5),
|
|
spreadRadius: 5,
|
|
blurRadius: 8,
|
|
offset: Offset(0,
|
|
3), // changes position of shadow
|
|
),
|
|
],
|
|
color: ColorsManager.boxColor,
|
|
borderRadius: BorderRadius.all(Radius.circular(10))); |