divider_template.dart 681 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14
// 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 'template.dart';

class DividerTemplate extends TokenTemplate {
  const DividerTemplate(super.blockName, super.fileName, super.tokens);

  @override
  String generate() => '''
class _${blockName}DefaultsM3 extends DividerThemeData {
  const _${blockName}DefaultsM3(this.context) : super(
    space: 16,
15
    thickness: ${getToken("md.comp.divider.thickness")},
16 17 18 19 20 21 22 23 24 25
    indent: 0,
    endIndent: 0,
  );

  final BuildContext context;

  @override Color? get color => ${componentColor("md.comp.divider")};
}
''';
}