पैकेज, रिपॉज़िटरी और ऐप श्रेणियाँ खोजें

sleek_button कवर
पैकेज विवरणv0.2.0

sleek_button

एक सरल लेकिन फिर भी कस्टमाइज़ करने योग्य बटन।

30-दिन डाउनलोड
13
लाइक
19
Pub अंक
40

पैकेज इंस्टॉल करें

flutter pub add sleek_button

पैकेज अवलोकन

सार्वजनिक जानकारी से बना चयन मार्गदर्शन। केवल संदर्भ हेतु।

Sleek Button एक हल्का, कस्टमाइज़ेबल Flutter विजेट है जो न्यूनतम प्रयास में आकर्षक और आधुनिक बटन बनाने के लिए डिज़ाइन किया गया है। यह विभिन्न प्रभावों के साथ बटन को स्टाइल करने के लिए एक साफ एपीआई प्रदान करता है, जिसमें एनीमेशन, ग्रेडिएंट और छाया शामिल हैं। भारी निर्भरता के बिना एक सरल लेकिन दृश्य रूप से आकर्षक बटन घटक की तलाश करने वाले डेवलपर्स के लिए उपयुक्त। पैकेज आकार, रंग, आकृति और रिपल प्रभाव के कस्टमाइज़ेशन का समर्थन करता है, जिससे यह बुनियादी और उन्नत UI की आवश्यकताओं के लिए उपयुक्त होता है। यह किसी भी Flutter प्रोजेक्ट में बिना किसी अड़चन के एकीकृत हो सकता है।

उपयोग

  • मोबाइल ऐप्स में स्टाइल्ड बटन बनाना
  • एनिमेटेड बटन प्रभाव जोड़ें
  • आकर्षक इनपुट कंट्रोल के साथ फॉर्म बनाना
  • इंटरैक्टिव UI तत्वों का डिज़ाइन करना
  • कस्टम बटन थीम का अनुप्रयोग
  • उपयोगकर्ता इंटरफेस की सुंदरता में सुधार करना

मुख्य विशेषताएँ

  • उच्च रूप से कस्टमाइज़ किया गया दिखावट
  • निर्मित एनीमेशन और रिपल प्रभाव
  • घेराव और छाया का समर्थन
  • सरल और स्पष्ट एपीआई
  • हल्का और तेज प्रदर्शन
  • मौजूदा फ्लटर प्रोजेक्ट्स के साथ आसान एकीकरण

इनके लिए उपयुक्त

  • Flutter शुरुआती उपयोगी विजेट्स के लिए तलाश रहे हैं
  • त्वरित बटन स्टाइलिंग चाहने वाले डेवलपर्स
  • चिकनी यूआई घटकों की आवश्यकता वाले प्रोजेक्ट
  • दृश्य आकर्षण और अंतरक्रिया पर केंद्रित ऐप्स
  • स्क्रीन पर सुस्त बटन डिज़ाइन के लिए लक्ष्य रखने वाली टीमें

विचार योग्य बातें

  • बटन-विशिष्ट कार्यक्षमता तक सीमित
  • लोडिंग या अक्षम जैसे जटिल राज्यों के लिए निर्मित समर्थन नहीं है
  • उन्नत इंटरैक्शन के लिए अतिरिक्त कोड की आवश्यकता हो सकती है
  • अत्यधिक डायनामिक या डेटा-आधारित बटन तर्क के लिए आदर्श नहीं है

मूल README

संबंधित सोर्स रिपॉज़िटरी के मूल README का स्नैपशॉट। नवीनतम सामग्री के लिए रिपॉज़िटरी देखें।

A simple but yet customizable button.

Install

Add the dependency to your pubspec.yaml :

dependencies:
    sleek_button: <version>

Quick start

SleekButton(
    onTap: () {
        print('tapped!');
    },
    style: SleekButtonStyle.flat(
        color: swatch.primary,
        inverted: true,
        rounded: true,
        size: SleekButtonSize.big,
        context: context,
    ),
    child: const Icon(Icons.format_bold),
)

Usage

Widget
SleekButton(
    onTap: () {
        print('tapped!');
    },
    style: <style>
    child: const Text('Save'),,
)
SleekButton(
    onTap: () {
        print('tapped!');
    },
    style: <style>
    child: Row(
        mainAxisSize: MainAxisSize.min,
        children: <Widget>[
            const Icon(Icons.check),
            const SizedBox(width: 6),
            const Text('Save'),
        ],
    ),
)

If the direct child is an Icon, the button will be a square.

SleekButton(
    onTap: () {
        print('tapped!');
    },
    style: <style>
    child: const Icon(Icons.check),
)
Styles
Flat
SleekButtonStyle.flat(
    context: context,
)
SleekButtonStyle.flat(
    size: SleekButtonSize.small,
    context: context,
)
SleekButtonStyle.flat(
    inverted: true,
    context: context,
)
SleekButtonStyle.flat(
    rounded: true,
    context: context,
)
SleekButtonStyle.flat(
    size: SleekButtonSize.medium,
    rounded: true,
    context: context,
)
Outlined
SleekButtonStyle.outlined(
    context: context,
)
SleekButtonStyle.outlined(
    size: SleekButtonSize.small,
    context: context,
)
SleekButtonStyle.outlined(
    inverted: true,
    context: context,
)
SleekButtonStyle.outlined(
    rounded: true,
    context: context,
)
SleekButtonStyle.outlined(
    size: SleekButtonSize.medium,
    rounded: true,
    context: context,
)
Light
SleekButtonStyle.light(
    context: context,
)
SleekButtonStyle.light(
    size = SleekButtonSize.small,
    context: context,
)
SleekButtonStyle.light(
    rounded = true,
    context: context,
)
SleekButtonStyle.light(
    size: SleekButtonSize.medium,
    rounded = true,
    context: context,
)
Colors

If you give a color, all variants (dark, light, invert) will be calculated with the help of the derived_colors package.

SleekButtonStyle.flat(
    color: const Color(0xFF)
    context: context,
)
 SleekButtonStyle.light(
    color: const Color(0xFFFFC369),
    context: context,
)
SleekButtonStyle.outlined(
    color: const Color(0xFF323232),
    context: context,
)
Theme

You can customize the default appearance of the button by adding a SleekButtonTheme in the tree. If a Theme is in the tree, it will use it tu deduce a default theme.

SleekButtonTheme(
    data: const SleekButtonThemeData(
        padding: 24,
        textStyle: TextStyle(fontSize: 11),
        cornerRadius: 8.0,
        iconTheme: IconThemeData(size: 10),
        fill: Color(0xFFFF0000),
        borderWidth: 2,
    ),
    child: app,
)

Thanks

Thanks to the bulma framework team for the inspiration.

श्रेणियाँ

निर्भरताएँ

निर्भरता सूची 3 आइटम

सोर्स रिपॉज़िटरी

इस पैकेज का उपयोग करने वाले प्रोजेक्ट

अभी कोई डेटा उपलब्ध नहीं है।