=== BrightTally ===
Contributors: michaelloeffler
Tags: polls, surveys, voting, forms, interactive, engagement
Requires at least: 5.0
Tested up to: 6.4
Requires PHP: 7.4
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Donate link: https://brighttally.com/download/bright-tally-wordpress-plugin

Embed interactive polls and surveys from BrightTally directly into your WordPress site. Create engaging content with real-time results and analytics.

== Description ==

BrightTally is a powerful WordPress plugin that allows you to easily embed interactive polls and surveys from your BrightTally account directly into your WordPress posts, pages, and widgets.

= Key Features =

* **Easy Integration**: Simple shortcode system and Gutenberg block for embedding polls anywhere
* **OAuth Authentication**: Secure connection to your BrightTally account with one-click setup
* **Account Creation**: Create a BrightTally account directly from WordPress
* **Real-time Results**: Live poll results and analytics
* **Customizable Themes**: Light and dark themes to match your site
* **Responsive Design**: Looks great on all devices
* **Visual Poll Picker**: Browse and select polls from your dashboard
* **Onboarding Wizard**: Step-by-step setup guide for first-time users
* **Multiple Poll Types**: Support for various poll and survey formats
* **Voting Controls**: Enable or disable voting as needed
* **Results Display**: Show or hide poll results
* **API Integration**: Secure connection to your BrightTally account

= How It Works =

1. **Connect Account**: Sign in to BrightTally or create a new account (OAuth)
2. **Create Polls**: Create polls in your BrightTally dashboard or use existing ones
3. **Embed Polls**: Use shortcodes or the Gutenberg block to embed polls
4. **Engage Users**: Visitors can vote and see results in real-time

= Shortcode Usage =

Basic usage:
`[bright_tally id="your-poll-id"]`

Advanced usage with options:
`[bright_tally id="your-poll-id" theme="dark" width="100%" show_results="true" allow_voting="true"]`

= Available Attributes =

* `id` - The poll ID (required)
* `theme` - Poll theme: "light" or "dark" (default: "light")
* `width` - Poll width: "100%", "500px", etc. (default: "100%")
* `height` - Poll height: "auto", "300px", etc. (default: "auto")
* `show_results` - Show results: "true" or "false" (default: "false")
* `allow_voting` - Allow voting: "true" or "false" (default: "true")

= Installation =

1. Upload the plugin files to `/wp-content/plugins/bright-tally/`
2. Activate the plugin through the 'Plugins' screen in WordPress
3. Go to BrightTally > Settings and connect your account (OAuth recommended)
4. Start embedding polls with shortcodes or the Gutenberg block!

= Configuration =

**OAuth Connection (Recommended):**
1. Go to BrightTally > Settings
2. Click "Sign In to BrightTally" or "Create New Account"
3. Follow the OAuth flow to connect your account
4. Start using the plugin immediately!

**Manual API Token Setup (Advanced - Pro/Agency/Enterprise Only):**
1. Go to BrightTally > Settings
2. Click "Enter API Token"
3. Get your API token from BrightTally (requires Pro plan or higher):
   - Log in to brighttally.com
   - Go to Profile menu → API Tokens (only visible for Pro/Agency/Enterprise plans)
   - Create a new token and copy it
4. Paste the token in WordPress
5. Save and test the connection

Note: OAuth connection is recommended and works for all plans. API tokens are only available for paid plans.

= Documentation =

Complete documentation is available at:
* **WordPress Plugin Docs**: https://brighttally.com/docs/wordpress
* **Getting Started**: https://brighttally.com/docs/wordpress/setup
* **Embedding Guide**: https://brighttally.com/docs/wordpress/manage/embedding-polls-and-forms
* **Troubleshooting**: https://brighttally.com/docs/wordpress/troubleshooting
* **Full Documentation**: https://brighttally.com/docs

You can also access documentation from the WordPress admin:
* Go to **BrightTally > Documentation** in your WordPress admin menu
* Click **"Show Help"** button in the BrightTally dashboard
* Use the help panel on any BrightTally admin page

= Frequently Asked Questions =

= Do I need a BrightTally account? =

Yes, you need a BrightTally account to create and manage polls. You can sign up for free at [brighttally.com](https://brighttally.com).

= How do I get my API token? =

API tokens are optional and only available for Pro, Agency, and Enterprise plans. OAuth connection is recommended and works for all plans.

If you have a paid plan and need an API token:
1. Log in to brighttally.com
2. Click your profile menu (top right)
3. If you have Pro/Agency/Enterprise, you'll see "API Tokens"
4. Create a new token
5. Copy it (you'll only see it once!)

If you don't see "API Tokens" in your menu, you're on the Free plan. Use OAuth connection instead - it's easier!

= Can I customize the appearance of polls? =

Yes! You can choose between light and dark themes, and customize the width and height of polls using shortcode attributes.

= Can I disable voting on polls? =

Yes, you can disable voting by setting `allow_voting="false"` in the shortcode. This is useful for displaying poll results only.

= Can I show results without allowing voting? =

Yes, you can show results without allowing voting by setting `show_results="true"` and `allow_voting="false"`.

= Are polls responsive? =

Yes, all polls are fully responsive and will look great on desktop, tablet, and mobile devices.

= Can I use polls in widgets? =

Yes, you can use the shortcode in any widget that supports shortcodes, such as the Text widget.

= Is there a Gutenberg block? =

Yes! The plugin includes a Gutenberg block with a visual poll picker. Just search for "BrightTally" in the block inserter.

= How do I connect my account? =

You can connect via OAuth (recommended) by clicking "Sign In to BrightTally" in Settings, or use manual API token setup for advanced users who need programmatic access.

= Will disconnecting or uninstalling the plugin delete my BrightTally account? =

No! Disconnecting or uninstalling the plugin will NOT close or delete your BrightTally account. Your account, polls, and all data remain safe on brighttally.com. Disconnecting only removes the WordPress connection - you can reconnect at any time. Uninstalling only removes the plugin from WordPress - your BrightTally account is completely separate and unaffected.

= Changelog ==

= 1.0.0 =
* Initial release
* Basic poll embedding functionality
* Shortcode support
* Admin dashboard
* API integration
* Responsive design
* Light and dark themes

== Upgrade Notice ==

= 1.0.0 =
Initial release of BrightTally WordPress plugin.
