codifyiq_group_manager 1.0.0 copy "codifyiq_group_manager: ^1.0.0" to clipboard
codifyiq_group_manager: ^1.0.0 copied to clipboard

Material 3 widgets for managing flat authorization groups and assigning one or more of them to users.

example/README.md

codifyiq_group_manager example #

import 'package:codifyiq_group_manager/codifyiq_group_manager.dart';
import 'package:flutter/material.dart';

final controller = GroupManagerController(
  groups: const [
    Group(id: 'admins', name: 'Administrators', icon: Icons.admin_panel_settings),
    Group(id: 'editors', name: 'Editors'),
  ],
);

// Catalog management:
Widget buildCatalog() => GroupManagerView(controller: controller);

// Assign groups to a user:
Widget buildAssignment(String userId) => ListenableBuilder(
  listenable: controller,
  builder: (context, _) => GroupAssignmentField(
    label: 'Groups',
    groups: controller.groups,
    selected: controller.groupsFor(userId),
    onChanged: (ids) => controller.setAssignments(userId, ids),
  ),
);

A runnable catalog demonstrating every CodifyIQ component lives in the example/ app at the repository root.

0
likes
160
points
285
downloads

Documentation

API reference

Publisher

verified publishercodifyiq.com

Weekly Downloads

Material 3 widgets for managing flat authorization groups and assigning one or more of them to users.

Repository (GitHub)
View/report issues

Topics

#codifyiq #ui #widget #authorization

License

MIT (license)

Dependencies

flutter

More

Packages that depend on codifyiq_group_manager