title: Hide the bottom line and change the style of the selected element Drowdown_button2
body: <p>I need your help. I'm using <code>dropdown_button2</code> from <a href="https://pub.dev/packages/dropdown_button2" rel="nofollow noreferrer">pub.dev</a> but I've run into a few issues that I can't resolve. <strong>First mistake</strong>: how to change the text style of the selected element? I need the text that displays the selected item to be larger. The <strong>second mistake</strong>: you need to remove the bottom line, which is displayed under the selected element, when the element is not selected, there is no line, only the element is selected - the line appears. Below I have attached screenshots of what I have now and what I need to get in the end. I would appreciate your help.</p>
  <p><strong>dropdown</strong></p>
  <pre><code>Widget build(BuildContext context) {
      return Container(
        width: 120,
        decoration: BoxDecoration(
          border: Border(
            bottom: selectedValue != null
                ? const BorderSide(
                    color: constants.Colors.white,
                  )
                : BorderSide.none,
          ),
        ),
        child: DropdownButtonHideUnderline(
          child: DropdownButton2(
            hint: const Text(
              'Select',
              style: constants.Styles.bigBookTextStyleWhite,
            ),
            items: widget.items
                .map((item) =&gt; DropdownMenuItem&lt;String&gt;(
                      value: item,
                      child: Container(
                        decoration: BoxDecoration(
                          border: Border(
                            bottom: BorderSide(
                              color: constants.Colors.white.withOpacity(0.1),
                              width: 1,
                            ),
                          ),
                        ),
                        child: Center(
                          child: Row(
                            children: [
                              if (item == selectedValue)
                                const SizedBox(
                                  width: 0,
                                ),
                              Expanded(
                                child: Text(
                                  item,
                                  style: constants.Styles.smallTextStyleWhite,
                                ),
                              ),
                              if (item == selectedValue)
                                const Icon(
                                  Icons.check,
                                  color: constants.Colors.purpleMain,
                                ),
                            ],
                          ),
                        ),
                      ),
                    ))
                .toList(),
            value: selectedValue,
            onChanged: (value) {
              setState(() {
                selectedValue = value as String;
              });
            },
            icon: SvgPicture.asset(constants.Assets.arrowDropdown),
            iconSize: 21,
            buttonHeight: 27,
            buttonElevation: 1,
            itemHeight: 47,
            dropdownMaxHeight: 191,
            dropdownWidth: 140,
            dropdownDecoration: BoxDecoration(
              borderRadius: BorderRadius.circular(8),
              border: Border.all(
                color: constants.Colors.purpleMain,
              ),
              color: constants.Colors.greyDark,
            ),
            selectedItemBuilder: (context) {
              return widget.items.map((item) {
                return Center(
                  child: Text(
                    item,
                    style: constants.Styles.smallTextStyleWhite,
                  ),
                );
              }).toList();
            },
          ),
        ),
      );
    }
  </code></pre>
  <p><strong>at the moment I have</strong></p>
  <p><a href="https://i.stack.imgur.com/GFkO8.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/GFkO8.jpg" alt="enter image description here" /></a></p>
  <p><strong>should be the result</strong></p>
  <p><a href="https://i.stack.imgur.com/LsfOo.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/LsfOo.jpg" alt="enter image description here" /></a></p>