bluesky_cards 0.1.0 copy "bluesky_cards: ^0.1.0" to clipboard
bluesky_cards: ^0.1.0 copied to clipboard

discontinued

Provide widgets to render Bluesky Social post beautifully in Flutter app.

bluesky_cards

The Easiest Widget to render Bluesky Social Post Nicely 🎯


GitHub Sponsor GitHub Sponsor

pub package Dart SDK Version Test/Analyzer codecov Issues Pull Requests Stars Contributors Last Commits License Contributor Covenant


1. Guide 🌎 #

Provide beautiful widgets to output Bluesky Social post content in Flutter app.

Show some ❤️ and star the repo to support the project.

The bluesky package is integrated into this package. So, by using the bluesky package together, you can easily create beautiful widgets!

1.1. Features 💎 #

EmbeddedCard

1.2. Getting Started ⚡ #

1.2.1. Install Library #

With Flutter:

 flutter pub add bluesky
 flutter pub add bluesky_cards

1.2.2. Import #

import 'package:bluesky/bluesky.dart';
import 'package:bluesky_cards/bluesky_cards.dart';

1.2.3. Implementation #

import 'package:bluesky/bluesky.dart' as bsky;
import 'package:bluesky_cards/bluesky_cards.dart' as bskyc;

import 'package:flutter/material.dart';

void main() {
  runApp(
    const MaterialApp(
      title: 'Bluesky Cards Demo',
      home: BlueskyCards(),
    ),
  );
}

class BlueskyCards extends StatelessWidget {
  const BlueskyCards({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: FutureBuilder(
        future: bsky.createSession(
          identifier: 'YOUR_HANDLE_OR_EMAIL',
          password: 'YOUR_PASSWORD',
        ),
        builder: (BuildContext context, AsyncSnapshot snapshot) {
          if (!snapshot.hasData) {
            return const CircularProgressIndicator();
          }

          final bsky.Session session = snapshot.data.data;
          final bluesky = bsky.Bluesky.fromSession(session);

          return FutureBuilder(
            future: bluesky.feeds.findFeeds(
              actor: session.did,
              limit: 5,
            ),
            builder: (BuildContext context, AsyncSnapshot snapshot) {
              if (!snapshot.hasData) {
                return const CircularProgressIndicator();
              }

              final List<bsky.FeedView> feed = snapshot.data.data.feed;

              return ListView.builder(
                itemCount: feed.length,
                itemBuilder: (BuildContext context, int index) {
                  return Card(
                    child: bskyc.EmbeddedCard.fromFeed(feed[index]),
                  );
                },
              );
            },
          );
        },
      ),
    );
  }
}

1.3. Supported Cards 👀 #

Name Description
EmbeddedCard This is a static card that neatly outputs a specific Post posted to Bluesky Social; it cannot trigger actions such as Like or Repost, but you can place the Post you wish to display anywhere you wish in the Flutter app.

1.4. Contribution 🏆 #

If you would like to contribute to bluesky_cards, please create an issue or create a Pull Request.

There are many ways to contribute to the OSS. For example, the following subjects can be considered:

  • There are request parameters or response fields that are not implemented.
  • Documentation is outdated or incomplete.
  • Have a better way or idea to achieve the functionality.
  • etc...

You can see more details from resources below:

Or you can create a discussion if you like.

Feel free to join this development, diverse opinions make software better!

1.5. Support ❤️ #

The simplest way to show us your support is by giving the project a star at GitHub and Pub.dev.

You can also support this project by becoming a sponsor on GitHub:

You can also show on your repository that your app is made with bluesky_cards by using one of the following badges:

Powered by bluesky_cards Powered by bluesky_cards Powered by bluesky_cards

[![Powered by bluesky_cards](https://img.shields.io/badge/Powered%20by-bluesky_cards-00acee.svg)](https://github.com/myConsciousness/atproto.dart)
[![Powered by bluesky_cards](https://img.shields.io/badge/Powered%20by-bluesky_cards-00acee.svg?style=flat-square)](https://github.com/myConsciousness/atproto.dart)
[![Powered by bluesky_cards](https://img.shields.io/badge/Powered%20by-bluesky_cards-00acee.svg?style=for-the-badge)](https://github.com/myConsciousness/atproto.dart)

1.6. License 🔑 #

All resources of bluesky_cards is provided under the BSD-3 license.

Copyright 2023 Shinya Kato. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided the conditions.

Note
License notices in the source are strictly validated based on .github/header-checker-lint.yml. Please check header-checker-lint.yml for the permitted standards.

1.7. More Information 🧐 #

bluesky_cards was designed and implemented by Shinya Kato (@myConsciousness).

2
likes
130
points
72
downloads

Publisher

verified publisheratprotodart.com

Weekly Downloads

Provide widgets to render Bluesky Social post beautifully in Flutter app.

Homepage
Repository (GitHub)
View/report issues

Topics

#atproto #bluesky #widget

Documentation

API reference

Funding

Consider supporting this project:

github.com

License

BSD-3-Clause (license)

Dependencies

bluesky, cached_network_image, flutter, html_unescape, url_launcher

More

Packages that depend on bluesky_cards